I am using this command to pull specific properties from all the vmguests in vCenter. $vms = Get-View -Server $vcenter -ViewType VirtualMachine -Property Name,Config,Snapshot,Summary,CustomVa...
See more...
I am using this command to pull specific properties from all the vmguests in vCenter. $vms = Get-View -Server $vcenter -ViewType VirtualMachine -Property Name,Config,Snapshot,Summary,CustomValue,Guest,Runtime.Host,AvailableField,Value,Parent I want to use the same command against a specific list of vmguests listed in a text file. I don't want to use Get-VM because it's too slow. So I tried something like this, but it's not working. $computers = Get-Content "$PSScriptRoot\computers.txt" $vms = Get-View -Filter @{"Name" = $computers} -Server $vcenter -ViewType VirtualMachine -Property Name,Config,Snapshot,Summary,CustomValue,Guest,Runtime.Host,AvailableField,Value,Parent How can I run the Get-View command against a specific list of vmguests? Thanks