2.7 Cisco Discovery Protocol (CDP)
Cisco Discovery Protocol (CDP) Cisco proprietary protocol that is media- and protocol-independent and runs on all Cisco manufactured equipment over any Layer-2 protocol that supports Subnetwork Access Protocol (SNAP) frames including Ethernet, Frame Relay, and ATM. With CDP, network management applications can obtain the device type and the SNMP IP address of neighboring devices.
CDP allows network management applications to dynamically discover Cisco devices that are neighbors of already known devices, neighbors running lower-layer transparent protocols in particular. CDP runs over the data link layer only, not the network layer. Therefore, two systems that support different network layer protocols can learn about each other. Cached CDP information is available to network management applications. However, Cisco devices never forward a CDP packet. When new information is received, old information is discarded.
CDP is enabled by default but you can use the no cdp run global command to disable CDP. You can also disable CDP per interface by using the no cdp enable interface command. In Catalyst OS (CatOS), the command to globally disable CDP is set cdp disable. In CatOS, to disable CDP on a port, use the set cdp disable [mod/port] command.
To find out about neighboring Cisco routers or switches, use the show cdp neighbors command, which gives summary information of each router. You use the same command on a Catalyst switch. To get more detailed information about neighboring routers, use the show cdp neighbors detail command. From the output, you can gather neighbor information such as name, IP address, platform type, and IOS version.