Hello,
I am trying to find a way to extract the vCenter(VC) associated with a particular ESXi hosts?
I can find the VC:HostSystem but cannot seem to figure out how to link this back to the vCenter. I cannot use "EsxiHost.parent.parent.parent" as the host might not be part of a cluster. Might only be under a DC. I looked under the HostConfig, About, Summary but could not find anything related to VC.
I could find all the hosts of a VC and then compare that array with my array of hosts but, that is ugly.
I did find an option to get the managedserverip which is the Ip of VC and then do a nslookup but, again ugly.
Any suggestions would be great. I am writing this workflow in JS.
Thanks
B