travis' brain dump

SCVMM Error 12711

by on May.19, 2017, under General

So while working on some virtual machines in the clusters we’ve been upgrading I’ve run across this error a couple of times and I figured it merited a post as one of the errors thrown in the mix wasn’t easily found in any solution online. 

Primary Error Description: 

Error (12711)
VMM cannot complete the WMI operation on the server (CLUSTERNAME) because of an error: [MSCluster_ResourceGroup.Name=”12df9151-eb2a-46e7-8a3e-58ae746b8783″] Not found
Unknown error (0x1002)

-or-

Error (12711)
VMM cannot complete the WMI operation on the server (CLUSTERNAME) because of an error: [MSCluster_ResourceGroup.Name=”12df9151-eb2a-46e7-8a3e-58ae746b8783″] The cluster resource could not be found  
The cluster resource could not be found (0x138F)

0x138F can be resolved by running the following in the VMM powershell: 

Get-ClusterResource -c CLUSTER.FQDN |Where {$_.ResourceType.Name -eq ‘Virtual Machine Configuration’} | Update-ClusterVirtualMachineConfiguration

0x1002 may require a little more involved work. However, before we dig into that one, make sure it’s not just some WMI problem on the host holding the cluster resources. Go into Failover Cluster Manager, right-click the cluster, hit more-actions and move core cluster resources to any other host. If this clears it up, great. If not, continue forward. 

I’ve had some success with pulling the resource and re-registering it. To accomplish this, you’ll need to remove the cluster resource and bring it back in as an update won’t cut it.

From the Failover Cluster Manager, find the virtual machine in the Failover Cluster Manager. Right click the resource and remove the item. It won’t delete it, but will remove the resource from the cluster and return it to the host it’s running on as a regular VM.

Once removed, expand the cluster name, right-click ‘Roles’ and select ‘Configure Roles’. In the list presented, select ‘Virtual Machine’ and click ‘Next’. You should see the machine you just removed in the list. Select it and complete the process to bring the resource back into the cluster. From VMM you should now be able to right-click the machine and select ‘Repair’ and ‘Ignore’ to resolve the issue. 

This issue is provided as-is with no warranty and if you end up deleting your VM, you’re on you own. 🙂 

Leave a Comment more...

MPIO on Nano Server

by on May.10, 2017, under Tech Stuff

After hunting around a little bit I found some great information on enabling and configuring MPIO on Nano Server. I figured, as always, I record down my thoughts here so I can reference them again later if needed and post it out publicly where it can be of some use to anyone wandering by. 

Useful Links: 

General information on MPIO from TechNet: Multpath I/O Overview

To enable MPIO on Nano Server, execute the following over your remote powershell session: 

Enable-WindowsOptionalFeature -Online -FeatureName MultiPathIO

Once enabled your SAN disks will be presented as duplicates (just as they are with MPIO under Windows Server), so you’ll need to execute additional powershell in order to claim or manage disks. 

Thankfully, Microsoft has published a script for this which can be downloaded from here: MPIO on NanoServer

It’s straight forward and works as designed, which feels odd sometimes when talking about Microsoft. 🙂 

Leave a Comment more...

Get BlockSize of Disks Using WMI & Powershell

by on Apr.12, 2017, under Tech Stuff

Ok, so I couldn’t find this earlier on the web easy enough, so I figured I’d stick it here for later if I ever need it again. I was trying to verify that my scripts had correctly formatted the volumes for SQL data with the correct block size. This should come in handy for anything else you need to verify block size with as well. 

$WMIQuery = “SELECT Label, Blocksize, Name FROM Win32_Volume WHERE FileSystem=’NTFS'”
Get-WmiObject -Query $WMIQuery -ComputerName ‘.’ | Select-Object Label, Blocksize, Name

Leave a Comment more...

Installing ADFS to Server Core (2016)

by on Oct.03, 2016, under Tech Stuff

This post assumes you have already completed your installation of Windows Server 2016 and configured IP addressing, domain join, etc.
(* this can easily be accomplished by running ‘sconfig.cmd’ when you first login so it’s not worth a full post)

To get started, login as a domain administrator for the system and complete the following commands on the prompt presented:

– ‘powershell’
– ‘Install-WindowsFeature ADFS-Federation’

This should install all necessary feature related items for ADFS on the system.

Another key component will be your SSL cert. Whatever you will be using, preferably a certificate for adfs.yourdomain.com or *.yourdomain.com, I recommend you export it out with private key in PFX format. Once completed, you’ll need to make sure you copy your certificate pfx out to the machine(s) and then execute the following:

– ‘certutil -importpfx <Path to certificate file>’

You can confirm your certificate installation and snag the thumbprint by executing the following:

– ‘dir cert:\LocalMachine\My’

If you’re setting up the first machine in a farm execute the following commands:

(this method uses a domain user/service account):
– ‘$ADFSCred = Get-Credential’ (input the credentials for your service account) 
– ‘Install-AdfsFarm -CertificateThumbprint:<thumbprint> -FederationServiceDisplayName:”Test Lab” – FederationServiceName:”adfs.testlab.com” -ServiceAccountCredential $ADFSCred -OverwriteConfiguration’

(this method used a group managed service account (the $ is required): 
– ‘Install-AdfsFarm -CertificateThumbprint:<thumbprint> -FederationServiceDisplayName:”Test Lab” – FederationServiceName:”adfs.testlab.com” -GroupServiceAccountIdentifier <DOMAIN>\<serviceaccount>$ -OverwriteConfiguration’

Additionally if you want to allow for logins using an email address as username, run the following:

– ‘Set-AdfsClaimsProviderTrust -TargetIdentifier “AD AUTHORITY” -AlternateLoginID mail -LookupForests domain.com’

This should get the initial setup of ADFS running for you on the main machine. 

To add additional machines to the farm (up to four using WID) you install all features, SSL certificate, etc. however, instead of installing the farm, you will add a node. You will execute this from each member node you wish to add, assuming SERVER1 is the name of the initial ADFS instance you setup and you’re running this on SERVER2.

(this method uses a domain user/service account):
– ‘$ADFSCred = Get-Credential’ (input the service account credentials you listed above)

– ‘Add-AdfsFarmNode -ServiceAccountCredential $ADFSCred -PrimaryComputerName SERVER1 -CertificateThumbprint <thumprint> -OverwriteConfiguration’

(this method used a group managed service account (the $ is required): 
– ‘Add-AdfsFarmNode -GroupServiceAccountIdentifier <DOMAIN>\<serviceaccount>$ -PrimaryComputerName SERVER1 -CertificateThumbprint <thumprint> -OverwriteConfiguration’

You should see a success message. If you do not, you can troubleshoot by testing out the farm configuration with the following commands:

– ‘$ADFSCred = Get-Credential’ (input the service account credentials)
– ‘Test-AdfsFarmJoin -ServiceAccountCredential $ADFSCred -PrimaryComputerName SERVER1’
*** If you plan on migrating from 2012R2 to 2016, you will need to set your newly installed 2016 secondary as a primary. 

From  your secondary box, run the following command: 
Set-AdfsSyncProperties -Role PrimaryComputer

You can then run the following to check it’s role: 
Get-ADFSSyncProperties

If you have other secondary machines, make sure to update their configuration to point to the new primary: 
Set-AdfsSyncProperties -Role SecondaryComputer -PrimaryComputerName <FQDN of ADFS Primary Server>

Once you’ve verified your new machine is running primary, you remove the old instances from the farm with Remove-ADFSFarmNode. 

 

Leave a Comment more...

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!