Neighbour Discovery Protocols – Part 4 (CDP Configuration with Packet Tracer)

CDP Packet Tracer Example

Packet Tracer CDP Configuration

 

As we have talked about in the previous lesson, CDP is a Cisco proprietary Neighbor Discovery Protocol. In this article, we will discuss how to configure CDP in Cisco IOS, we will learn CDP Cisco Configuration. LLDP is a standard neighbour discovery protocol. In another lesson we will also configure LLDP.

 

You can DOWNLOAD the Packet Tracer example with .pkt format HERE.

 


For all Packet Tracer Examples and Files, you can check Packet Tracer Labs Page.


 

For our example, the below topology is used.

CDP Configuration Topology
CDP Configuration Topology
Above, there is a L2 swith, a L3 switch, a router, an IP Phone and a PC are connected to the central switch.

 

We will not talk about the configuration of the central switch, but we will talk about the general CDP configuration commands.

 


 

To enable CDP globally, use “cdp run” on the router configuration mode.

 

Switch(config)# cdp run

 

To enable CDP on a specific interface, use “cdp enable” command on the interface configuration mode. By default CDP is already enabled. You can also disable CDP by using “no cdp enable” command.

 

Switch(config-if)# cdp enable
Switch(config-if)# no cdp enable

 


 

To configure cdp Hello time and Hold time, you can use the below commands. Time is mentioned as seconds.

 

Switch(config)# cdp timer 50
Switch(config)# cdp holdtime 100

 


 

To clear the CDP table, use the “clear cdp table” command.

 

Switch# clear cdp table

 


 

To verify CDP, you can use general CDP verification commands below:

Switch# show cdp
Switch# show cdp interface
Switch# show cdp neighbors
Switch# show cdp entry
Switch# show cdp traffic

 

In our topology, for the central switch, “show cdp neighbours” and “show cdp interface” command outputs are showed below.

 

Switch>show cdp neighbors

Capability Codes: R – Router, T – Trans Bridge, B – Source Route Bridge
S – Switch, H – Host, I – IGMP, r – Repeater, P – Phone
Device ID Local Intrfce Holdtme Capability Platform Port ID
IP Phone Fas 0/4 124 H P 7960
Switch Fas 0/6 124 3560 Fas 0/1
Switch Fas 0/2 124 S 2960 Fas 0/2
Router Fas 0/5 124 R C2800 Fas 0/0
Switch Fas 0/1 124 S 2950 Fas 0/1

 


For all Packet Tracer Examples and Files, you can check Packet Tracer Labs Page.


 

One Response to “Neighbour Discovery Protocols – Part 4 (CDP Configuration with Packet Tracer)”


  • Antony Maraka / / Reply

    There is nothing more good than waking up very early and sleeping very late in the night going through the Tutorials found on this site.
    Eng Gokhan, you are a blessing to me brother.

    Maraka in Nairobi, Kenya

Leave a Reply

Your email address will not be published. Required fields are marked *