I'm guessing this is a bug, but has anyone else noticed that the Get-VMHostAuthentication cmdlet requires an ESX host to be in 'Connected' status. 'Maintenance' is not a valid status for it. I'm assuming there is a reason for this?
As part of my installation process, I have a script joining the system to the domain (among several other things) and would rather not take the host out of maintenance, until I've finished configuration.
Thanks guys, we will take a look at this for a future version
To clarify, I'm running vCenter 4.1 U1 w/ ESXi 4.1 U2 hosts currently.
Maybe the hosts aren't reflecting their connection state correctly?
I do get the following error when I do a Get-VMHost Authentication on a vCenter 5 with an ESX 4.1U1 that is in maintenance mode.
Get-VMHostAuthentication : 13-03-2012 07:13:50 Get-VMHostAuthentication The host must be in the following state: Connected.
This works from the vSphere Client and the JoinDomain_Task method, so I suspect this is an obsolete requirement.
As a bypass you could use the script from my Script vSphere 4.1 AD Authentication post.
Blog: lucd.info Twitter: @LucD22 Co-author PowerCLI Reference
Thanks guys, we will take a look at this for a future version
I bypassed it by simply doing the domain join as a first step rather than a last step, changing it to connect status and different placement in vCenter.
Then just placing it back into maintenance.
Thanks Alan.
I got same error when retrieve authentication from ESXi5.0 U1 in vCenter 5.0 with PowerCLI 5.0.
Error message below for your reference.