Hi Experts,
I wanted to run some powerCLI comments in vCenter that comment needs to fetch all the available esxi in vCenter and apply only when ESXi server is Gen9. Could someone give me the logic to sort out the Gen9 esxi servers and execute my comments
@scott28tt Thanks Scott for letting me post my powershell-related post here.
@LucD Earlier I have posted my question in different place. Hope this is the right place for Powershell. I am looking forward to hearing from you. Could you please post your answer here.
Try with
Get-VMhost |
Where{$_.ExtensionData.Hardware.SystemInfo.Model -match 'Gen9'} |
Foreach-Object -Process {
# Your commands
}
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Try with
Get-VMhost |
Where{$_.ExtensionData.Hardware.SystemInfo.Model -match 'Gen9'} |
Foreach-Object -Process {
# Your commands
}
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
@LucD
Hi Expert
Thanks Much.
Your code is perfect. ::)
Working as expected. Marked your answer as the right answer.