Files
PowerCLI-Example-Scripts/Scripts/Get-VMToolsParts.ps1
Jim Jones e70e50600f Create Get-VMToolsParts.ps1
Outputs the VMware Tool component installation state for all running Windows VMs in your environment.
2017-08-30 12:34:03 -07:00

12 lines
443 B
PowerShell

$vms = Get-VM | where {$_.PowerState -eq "PoweredOn" -and $_.GuestId -match "Windows"}
ForEach ($vm in $vms){
Write-Host $vm
$namespace = "root\CIMV2"
$componentPattern = "hcmon|vmci|vmdebug|vmhgfs|VMMEMCTL|vmmouse|vmrawdsk|vmxnet|vmx_svga"
(Get-WmiObject -class Win32_SystemDriver -computername $vm -namespace $namespace |
where-object { $_.Name -match $componentPattern } |
Format-Table -Auto Name,State,StartMode,DisplayName
)
}