$blogname

Find out which vCenter manages an ESX host.

with 2 comments

Ran into this problem today and didn’t see any info about it online. ESX stores the IP address of the vCenter that manages it in the HostConnectInfo object.

If you connect to ESX you can call QueryHostConnectionInfo on the HostSystem object to find out which vCenter manages it.

Here’s PowerCLI code that will do that.

Get-VMHost |
    Get-View -property Name |
    Foreach { $_.QueryHostConnectionInfo() } |
    Select ServerIp

Written by Carter Shanklin

May 24th, 2011 at 11:24 pm

Posted in Uncategorized

Tagged with , , ,

2 Responses to 'Find out which vCenter manages an ESX host.'

Subscribe to comments with RSS or TrackBack to 'Find out which vCenter manages an ESX host.'.

  1. well-written code! I like how you implement it. and it fits well into the interface

    essay company

    2 Nov 16 at 10:56 am

  2. Thanks for the information! I will be fixing my current problem using this special report.

Leave a Reply