VMware Cloud Community
MattCarey
Contributor
Contributor

Finding ESX server that any given VM is hosted on

A little background on this one. The guy that used to manage ESX and all VM's in our environment has suddenly left us, and now I am one one that has been elected to take over all of his duties. 😃

I have been presented with the task of taking a group of about 10 virtual servers and finding the parent ESX server they are hosted on.

I know the IP for the management interface for a few of the ESX servers in our enterprise, but they VM's in question are not hosted on any of these.

I do know the IP range that the VM's are in so the ESX host must be within the same range of that.

I have thought about scanning that particular IP subnet for known ESX ports, but wanted to check here to see if there is an easier way to trace VM's back to the parent ESX server? I'm sure I can't be the first person who has ran across this........or at least I hope not Smiley Wink

0 Kudos
12 Replies
sbeaver
Leadership
Leadership

No Virtual Center huh? I think you are going to find that if it is not in DNS then you are going to need to scan the network

Steve Beaver
VMware Communities User Moderator
VMware vExpert 2009 - 2020
VMware NSX vExpert - 2019 - 2020
====
Co-Author of "VMware ESX Essentials in the Virtual Data Center"
(ISBN:1420070274) from Auerbach
Come check out my blog: [www.virtualizationpractice.com/blog|http://www.virtualizationpractice.com/blog/]
Come follow me on twitter http://www.twitter.com/sbeaver

**The Cloud is a journey, not a project.**
0 Kudos
MattCarey
Contributor
Contributor

We are using Virtual Center for the ESX 3.0 machines that I have setup since taking the position over, but for the older ones (which may even be ESX 2.5) they just used the web interface (I think it's technically called the MUI in 2.5........?)

Anyhow, any recommendations on which port to scan for? 80 is an obvious choice, along with 22 I suppose.

0 Kudos
bister
Expert
Expert

The management port resp. the port the virtual center console connects to ESX (I think it also was 902 in 2.5) would be also one to scan for.

Respectfully,

Christian

0 Kudos
RParker
Immortal
Immortal

My advice is to download ESX charter, it's great for this. You add a host, and you can see your entire ESX farm (if you add all the appropriate hosts) and from there you can see ALL the VM's, and it will show which hosts they reside on.

http://www.vizioncore.com/

0 Kudos
bister
Expert
Expert

I think that's not exactly what he is looking for. He wants to find out the ESX hosts he doesn't know...

Respectfully,

Christian

0 Kudos
MattCarey
Contributor
Contributor

That sounds like a tool that may be helpful to me in the future (once I know all of the ESX hosts where abouts). I will definltely have to check that one out once I get my original problem resolved Smiley Happy

0 Kudos
MattCarey
Contributor
Contributor

I'll try that one as well, thanks for the advice everyone!

0 Kudos
artificalrealit
Contributor
Contributor

So where you able to find a tool or script for this?

0 Kudos
Paul_Lalonde
Commander
Commander

Run either an ' esxtop ' or ' ps -efw ' on each ESX box. It will show you what VMs are running on that particular server.

Paul

0 Kudos
Paul_Lalonde
Commander
Commander

Oops.. read that too fast! You don't know where all the ESX servers are...

I'll try again...

Log into any given VM and verify the Ethernet MAC address of the virtual NIC (with 'ipconfig /all')

Then, log into your network switch(es) and check the MAC address table. Whatever switch port that MAC address shows up under will either be 1) the ESX server port itself, or 2) an uplink port to another switch that will take you one step closer!!

Once you know which port the ESX server is using to host that VM, you're one step closer to finding the actual ESX box. It's all electrons, after all Smiley Happy

Regards,

Paul

0 Kudos
bister
Expert
Expert

Yeah, did you find something? Another (old school) method would be just to connect to the physical console of each server and see whats running. Hope you have s.th. like iLO/DRAC or some IP based KVM-solution ...

Respectfully,

Christian

0 Kudos
surkude
Contributor
Contributor

Did you find a way to figure out the ESX server that the VM is running on ? I am also looking for a solution to this problem.

thanks

0 Kudos