CDP (Cisco Discovery Protocol)
CDP is always automatically enable by default, unlike routing protocols. It offers several commands to find out detailed information about the neighboring routers (adjacent routers/switches only) to your primary host. The interface must support SNAP headers. CDP is Cisco proprietary, is always running in the background, so it does not rely on any particular Layer 3 protocol, and can find Layer 3 info on neighbors even if that protocol has not been configured on the router that issues the CDP command.
CDP uses it’s own proprietary “Subnetwork Access Protocol” to gather information about it’s neighbors
show cdp - lists the two timers, Send CDP Update Packets and Holdtime
show cdp neighbors - list basic info about the neighbors (*** memorize output, which is:
Device ID (Hostname), Local Interface, Holdtime, Capability (type of device – R Router, T Trans Bridge, B Source Route Bridge, S Switch, H Host, I IGMP, r Repeater), Platform (the model number), Port ID (the interface of the neighbor)
For example:
2501B Ser 0 19 R 2500 Ser 1
show cdp neighbors detail - list extensive info about the neighbors such as IP address
show cdp entry hostname - list extensive info about a particular neighbor NOTE: sh cdp entry * shows info about all connected (neighbors) routers
show cdp interface - list the primary host interfaces used to contact the neighbors, and encapsulation (such as ARPA for Ethernet, HDLC for serial, etc.)
show cdp traffic - list the amount of traffic that CDP is generating in packets
The default timers are : send CDP update packets every 60 secs
Holdtime Value = 180 secs (received info is held)
To change the update frequ to 90 secs, for example, goto config mode and type:
cdp timer 90
Sh CDP Neighbors – this command displays the following about each neighbor (router) :
HostName
Local Interface that the Neighbor is heard on
Holdtime - decremental holdtime
Capability (the device type – R for router, S for switch, etc)
Platform
Port ID (Interface of the neighbor)
to Disable CDP - no CDP enable