VMware Cloud Community
tdubb123
Expert
Expert
Jump to solution

get-esxcli error

getting this error when adding $esxcli to the script

any idea?

Capture.PNG

0 Kudos
1 Solution

Accepted Solutions
LucD
Leadership
Leadership
Jump to solution

Looks like you have an ESXi node in your vCenter that is not connected.

Change the line like this

foreach($vmhost in (Get-Cluster -Name $cluster | Get-VMHost -State Connected)){


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

View solution in original post

0 Kudos
2 Replies
LucD
Leadership
Leadership
Jump to solution

Looks like you have an ESXi node in your vCenter that is not connected.

Change the line like this

foreach($vmhost in (Get-Cluster -Name $cluster | Get-VMHost -State Connected)){


Blog: lucd.info  Twitter: @LucD22  Co-author PowerCLI Reference

0 Kudos
tdubb123
Expert
Expert
Jump to solution

nice . thanks

0 Kudos