You are currently viewing Cisco Discovery Protocol

Cisco Discovery Protocol

Cisco Discovery Protocol (CDP) is a powerful network monitoring and diagnostic tool. CDP is an information collection tool used by network administrators to obtain information about directly connected Cisco devices.

CDP Network Discovery

CDP is a proprietary tool that allows you to access the protocol summary and address information about Cisco devices that are directly connected. By default, each Cisco device sends periodic messages, which are known as CDP notifications, to directly connected Cisco devices. These notifications contain information, such as the types of devices that are connected, the interfaces of the router with which they are connected, the interfaces to which they are connected, and device model numbers.

Most network devices, by definition, do not work in isolation. A Cisco device typically has other Cisco devices as neighbors on the network. Information collected from other devices can help you make network design decisions, troubleshoot problems, and make hardware changes. CDP can be used as a network discovery tool, helping you create a logical network topology when such documentation is missing or lacking in detail.

Familiarity with the general concept of neighbors is important for understanding CDP as well as for future discussions about dynamic routing protocols.

Level 3 Neighbors

Currently, in our topology configuration, we have connected only the neighbors directly. At Layer 3, routing protocols assume that neighbors are devices that share the same network address space.

For example, R1 and R2 are neighbors. Both are network elements 172.16.2.0/24. R2 and R3 are also neighbors because they both share the 192.168.1.0/24 network. But R1 and R3 are not neighbors because they do not share the network address space. If we connected R1 and R3 with a cable and configured on each IP address of the same network, they would be neighbors.

Level 2 Neighbors

CDP only works in Layer 2. Therefore, CDP neighbors are Cisco devices that are directly connected physically and share the same data channel. In the CDP protocol illustration, the network administrator has logged into S3. S3 receives CDP notifications only from S1, S2, and R2.

In this topology, we can see that the following CDP neighbor relationships:

  • R1 and S1 are neighbors of the CDP.
  • R1 and R2 are neighbors of the CDP.
  • R2 and S2 are neighbors of the CDP.
  • R2 and R3 are neighbors of the CDP.
  • R3 and S3 are neighbors of the CDP.

Notice the difference between Layer 2 and Layer 3 neighbors. Switches are not neighbors of Layer 3 routers, because switches work only in Layer 2. However, switches are Layer 2 neighbors with their directly connected routers.