VMware Cloud Community
jlnmrx
Contributor
Contributor
Jump to solution

DISCOVER THE HOST THROUGH GUEST O.S.

Hello Sirs,

I have an issue that I thought was simple at first, but it's proving to be much more complicated. Smiley Sad

I have a Windows Server 2008 VM active and accessible through MSTSC. However, I don't know where this VM is hosted.

Then Hyper-Vi, for example, stores a registry key with the name of the Host, but there is no such thing in VMWare. I haven't found any host reference on the Guest O.S.

Objective: to discover the name/IP of the Host through VM itself.

Details:

1 - It's hosted on an isolated Host from vCenter, so there is no way to access it through vCenter Server;

2 - We don't have information about the name or IP of this Host.

3 - The ESXi version of this host is 5.5, so there's no way to use the vmtoolsd.exe tool with the --cmd "info-get" command because it works only with older versions of ESX / ESXi.

4 - The solution seems to be to use some tool inside the vmware tools package to find a "find" on that host, but I couldn't find it in vmware documentation and other related blogs.

All help is appreciated.

Thanks in advance!!!

1 Solution

Accepted Solutions
TheBobkin
Champion
Champion
Jump to solution

Hello jlnmrx​,

Depending on how you have this configured you may be able to use the MAC address of the VM compared to on switch(es) and determine which host this is connected to.

Other options: use RV Tools, use PowerCLI direct to hosts (connected to vCenter is not mandatory).

There *may* be something configurable in .vmx to provide such information but I can't see how much help this would be if you don't know which host it is on (and thus cannot access the .vmx) and regardless, any changes would require application and reboot of all VMs to apply.

Bob

View solution in original post

4 Replies
virtualg_uk
Leadership
Leadership
Jump to solution

I am not sure that you will have much luck doing this.

Can I ask what the "end goal" is here and maybe there is another way to solve this without looking from within the Guest OS?

As a side note, there are tools that you can use outside of the Guest OS such as PowerCLI which will get you the Host that a given Virtual Mchine is running on and also a wealth of information about the Guest OS inside that VM.


Graham | User Moderator | https://virtualg.uk
0 Kudos
jlnmrx
Contributor
Contributor
Jump to solution

Can I ask what the "end goal" is here and maybe there is another way to solve this without looking from within the Guest OS?

Some host migrations between vCenters in the past have left this and other virtual machines in this state. My mission is to discover the physical machine that hosts that virtual machine without having to visit the affiliate's datacenter for this.

As a side note, there are tools that you can use outside of the Guest OS such as PowerCLI which will get you the Host that a given Virtual Mchine is running on and also a wealth of information about the Guest OS inside that VM.

How would I use powercli for this without connecting it to a specific vcenter/host?

0 Kudos
virtualg_uk
Leadership
Leadership
Jump to solution

It sounds like the best approach would be to use PowerCLI however yes your computer would need access to the vCenter server to run the PowerCLI command


Graham | User Moderator | https://virtualg.uk
0 Kudos
TheBobkin
Champion
Champion
Jump to solution

Hello jlnmrx​,

Depending on how you have this configured you may be able to use the MAC address of the VM compared to on switch(es) and determine which host this is connected to.

Other options: use RV Tools, use PowerCLI direct to hosts (connected to vCenter is not mandatory).

There *may* be something configurable in .vmx to provide such information but I can't see how much help this would be if you don't know which host it is on (and thus cannot access the .vmx) and regardless, any changes would require application and reboot of all VMs to apply.

Bob