Ping a mac address to get it to reply and update mac address-table

arpmac addressping

I need to find out what port a MAC address is connected to.

Given a Cisco 3750, I can do a

show mac address-table dynamic

and see all the mac addresses that the switch has seen frames travelling to and from.

But I have a physical machine hosting some vms. That physical machine has two nics teamed and they trunk to this Cisco 3750. While the vms are actively communicating, the host machines aren't sending data so their macs aren't in the table.

I know from my sh mac address-table that the ports on the switch are 1/0/15 and 2/0/15 (it's a stack of two) because I can see the macs of the vms in the address table. But I want to know which of the switch ports is physically connected to eth0 and eth1 on the server. I know the macs of the physical nics. I just can't work out how to arp ping them from the switch and get some sort of reply.

Thanks in advance.

I should add that physically tracing the cables is out of the question and I need to do this remotely. I'll be putting the data in a visio chart.

Best Answer

This depends on what OS the VM's are running. If they're running Linux or some other UNIX variant you can use arping to accomplish this. If they're running Windows (XP/7/8), whenever a new IP address is added to an interface, Windows will send gratuitous ARPs for that IP address for duplicate address detection by default, so you may be able to get the MAC address that way.