Cisco Support Community
Community Member

Mac/IP/Port Native Commands

I'm looking for a command on Native 12.1 that gives me an output of port information containing which IP and mac address is directly connected to that port. Trying to cross reference the information with a list of servers so I can identify which server is plugged into which port.

I've tried sh mac-address-table and it give me port and mac but no IP.

Any help would be appreciated.


Re: Mac/IP/Port Native Commands

what kind of device are you talking about , router or switch . If it's a L2 switch then you will have to go up to the L3 device that does the routing to look it up in the arp table or if the router is running 12.0 or above and running CEF you can do a "show adjacency intx/x detail and this will give you the ip address,mac address and the dns name if it has one .

Community Member

Re: Mac/IP/Port Native Commands

It's a 6509 switch with SupII/MSFCII's. Native IOS and I'm not running CEF. Basic IP IOS.

The trouble is I cannot find a command that gives me all three ouputs to match up the port, mac, and ip. I can get output for ip and mac. I can also use another command to get mac and port but then I have to match up all entries manually one by one and there are 250+ devices on the switch.

Any ideas?

Community Member

Re: Mac/IP/Port Native Commands

You will have to do sh ip arp (on layer 3)and find the IP address that is associated with that mac address.

A faster way to find out would be (on layer 3):

sho ip arp | include xxxx.xxxx.xxxx (where xxxx.xxxx.xxxx is the mac address)

CreatePlease to create content