Last active
December 31, 2018 20:11
-
-
Save TScalzott/48d2f401696dc579eb9d7383e103de6f to your computer and use it in GitHub Desktop.
Find Cluster VMs Missing VMware Tools
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@("Cluster1", "Cluster2") | | |
ForEach-Object { | |
Get-Cluster -Name $_ | | |
Get-VM | Sort-Object Name | | |
Where-Object { $_.PowerState -eq "PoweredOn" } | | |
ForEach-Object { Get-View $_.ID } | | |
Where-Object { $_.Guest.ToolsVersionStatus -eq "guestToolsNotInstalled" } | | |
Select-Object Name, @{N = "Tools Version"; E = {$_.Config.Tools.ToolsVersion}}, | |
@{ N = "Status"; E = {$_.Guest.ToolsVersionStatus}} | | |
Format-Table -AutoSize | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment