This site is operated by a business or businesses owned by Informa PLC and all copyright resides with them. Informa PLC's registered office is 5 Howick Place, London SW1P 1WG. Registered in England and Wales. Number 8860726.
If you're a network analyst, sooner or later you'll encounter a situation where you need to verify, document or determine what port a device is connected to.
If you’re lucky, you can look at the cable or jack identifier, reference your network documentation and you are good to go. But what do you do when you can’t easily access the cables, they aren’t labeled or you believe they aren’t labeled correctly? Moreover, what do you do for remote troubleshooting?
With many switch vendors, there are network management platforms to easily perform a switch inventory using SNMP or Telnet/SSH access. Unfortunately, there are many situations where that isn’t possible. In this video, I demonstrate a free command-line tool that decodes Cisco Discovery Protocol (CDP) packets to see device identities, IP addresses, and port numbers to which a device is connected. Cisco Discovery Protocol Reporter (CDPR) is a handy utility that uses WinPcap to display CDP packets. I've used CDPR for more than 10 years and find it incredibly helpful.
You also can leverage CDP using manual commands on a Cisco platform if you are fortunate enough to have access. Another technique involves capturing a CDP packet using Wireshark, which does not require having access to the device.