Discussion Locked

Find a MAC or IP of a device on a port

0 helpful
5 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

Hi everyone
Does anyone know of a method of find out either the MAC or IP addresses of a device attached to a give port using IOS commands in a CISCO switch?

Thanks in advance

Daryl Sheppard
daryl_s@bigpond.com

5 replies

by kalon9999

Daryl,

One suggestion that I use is (in a VLAN'ed network) the command "show arp noalias" on an IOS Switch or "show arp" on your authoritative router.

The router will return all info - IP Address, MAC (arp) address, the interface it is connected to, the aging time for the MAC Address and the protocol used to get the info.

Hope this helps!

Kevin L
kalon9999@hotmail.com

by jbelcher

On Catalyst switches that run IOS you can use the following command to find the MAC address of hosts connected to the switch:

sho mac

This will return an overview of the static and dynamic MAC addresses known to the switch.

You may be able to further qualify this command (not sure which version this command was introduced in IOS):

sho mac dynamic interface f0/1 <- Replace with the interface your are wanting to look at.

This will give you the MAC address. Getting the IP address from the MAC address is a little more difficult. Here are some suggestions:

Use the 'show ip arp' command on cisco IOS switches and routers. The gateway router is a good place to look.

Use 'arp -a' from a windows/unix host to list the MAC/IP relationships that is known to that host.

Another good place is a DHCP server which should show MAC/IP bindings.

Keep in mind that the first three bytes ( 00:02:4b ) is a vendor code that can be looked up here: http://coffer.com/mac_find/

This discussion is closed to new replies.