CDP, ping from port

Unanswered Question
Sep 14th, 2005
User Badges:

Is there a way to log into a 2950 or 3550 and ping certain ports in order to find the IP of the device connected to it? Also how would I find the MAC of the device connected to a specific port?

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 0 (0 ratings)
Josef Oduwo Thu, 09/15/2005 - 01:16
User Badges:
  • Gold, 750 points or more

You can use CDP to find out information about directly connected Cisco devices.

Here is a link on configuring CDP for the 2950 series switches (which generally hold for most access switches)

For a particular port:

Switch#show cdp interface [type mod/number] so that

Switch#show cdp interface fastethernet 0/3 displays information only about Fastethernet port 3.


wrwiii122 Thu, 09/15/2005 - 18:17
User Badges:

But this does not let me see the IP for say a PC connected to the port.

Josef Oduwo Thu, 09/15/2005 - 20:49
User Badges:
  • Gold, 750 points or more

No it wouldn't.

To answer your original questions, because switches work at Layer 2 you would only be able to see Layer 2 traffic (MACs) and would not be able to pick up IP addresses of connected devices (Layer 3) by simply logging into a switch. To find the MAC of a device connected to a specific port use the user command:

Switch>show mac address-table interface interface-id [vlan vlan-id] [ | {begin | exclude | include} expression]

More on this command is available here:

You could also use SNMP:



burhamkri Fri, 09/16/2005 - 02:44
User Badges:

To find the IP address associated with a given MAC address, connect to the router for the subnet that the device is on and run "show arp"

You can speed up the process by only displaying the MAC/IP combo you are looking for with:

"show arp | include [MAC ADDRESS]"

Just make sure you get the mac-address format right.


This Discussion