The five best Windows PowerShell v3 commands every admin should know

4/6

Monitoring cluster resources with the Get-ClusterGroup cmdlet

The Get-ClusterGroup cmdlet is a part of Windows Server 2012's failover clustering feature, but it is extremely useful in virtual server environments. Most production virtual servers are clustered as a way of improving VM reliability. The Get-ClusterGroup cmdlet reports on the health of clustered VMs.

Running the Get-ClusterGroup cmdlet by itself will retrieve information about all clustered resources, which can include things other than VMs. To limit the list to VMs, you must include the Where GroupType –EQ 'VirtualMachine' option. The full <a href="https://searchservervirtualization.techtarget.com/tip/PowerShell-v3-in-Hyper-V-30-New-fun-for-command-line-junkies">PowerShell v3 command looks</a> like this:

Get-ClusterGroup | Where GroupType –EQ 'VirtualMachine' | Get-VM

The image shows the command in action. In the figure, I redirect the output to the Get-VM cmdlet to retrieve a list of clustered VMs; however, you can easily adapt this technique to perform any bulk operation on your clustered VMs.

View All Photo Stories

Start the conversation

Send me notifications when other members comment.

By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Please create a username to comment.

-ADS BY GOOGLE

SearchVMware

SearchWindowsServer

SearchCloudComputing

SearchVirtualDesktop

SearchDataCenter

Close