cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
411
Views
5
Helpful
2
Replies

Device IP on Switch Port

michael.ball
Level 1
Level 1

Does anyone know of a command or utility to extract the IP address of an end device on a particular port?

2 Replies 2

Bobby Thekkekandam
Cisco Employee
Cisco Employee

Hi Michael,

There's no command or utility to get this info. However, here is the general procedure.

1) Do a "show arp" on the router that is the default gateway for a given vlan.

2) Do a show "mac-address-table dynamic vlan x" on the switch you want to find said information on.

Cross reference the mac addresses and port numbers from the switch output with the mac address and IP associations from the show arp output.

IIRC there are some scripts on sourceforge or freshmeat that can help automate this.

HTH,

Bobby

*Please rate helpful posts

ankurbhasin
Level 9
Level 9

Hi Michael,

Its not a very easy task. If you know the port number on a switch on which end device is connected you can issue a command

"sh mac-address-table interface "

and get the mac addres learned on that port and if at all you have a layer 3 device connected to the switch you can issue a command

"sh ip arp "

and you will get an ip address binded with that mac address.

HTH, if yes please rate the post.

Ankur