Section 3-7. Cisco Discovery Protocol


3-7. Cisco Discovery Protocol

  • CDP is used to identify directly connected Cisco devices.

  • CDP is enabled on all Cisco devices.

  • CDP identifies neighbor address, operating system, VLAN, VLAN Trunking Protocol (VTP) domain, and duplex information between Cisco switches.

  • CDP can be disabled globally or on a per-port (interface) basis.

Configuration of CDP

1.

(Default) Enable CDP globally:

COS

 set cdp enable 

IOS

 (global) cdp run 


CDP is enabled by default. The default commands are shown in Step 1. To disable CDP for the entire device, use the command set cdp disable for COS devices or no cdp run for IOS devices.

2.

(Optional) Set the update time for CDP advertisements:

COS

 set cdp interval interval 

IOS

 (global) cdp timer interval 


CDP sends advertisements ever 60 seconds by default. Use these commands to change the update interval in seconds. Keep in mind that the update interval must be less than the holdtime.

3.

(Optional) Specify the holdtime of CDP information:

COS

 set cdp holdtime interval 

IOS

 (global) cdp holdtime interval 


If CDP does not hear an update for the specified amount of time in the holdtime interval in seconds, that information is purged from the CDP table. Use these commands to change the holdtime. The holdtime should be greater than the advertisement (usually three times the value of the update timer).

4.

(Default) Set the CDP version send parameters for the switch:

COS

 set cdp version {v1 | v2} 

IOS

 (global) cdp {advertise-v2 | advertise-v1} 


CDP has two versions (v1 and v2). These versions are compatible, but version 2 has enhanced type-length-values (TLVs) that support VTP domain name, native VLAN, and duplex information. This information is very important in the operation of switch ports. If you receive CDP mismatch messages, the errors are not fatal, but they can indicate a problem.

5.

(Optional) Disable CDP on an interface or port:

COS

 set cdp disable mod/port 

IOS

 (interface)no cdp enable 


CDP is enabled by default on every port. For ports that are not connected to Cisco devices, it makes no sense to have CDP running. Use the commands in Step 2 to disable CDP on a port-by-port basis. To reenable CDP, use the command set cdp enable mod/port for COS devices and cdp enable for IOS switches.

The command show cdp displays global information about CDP configuration on both operating systems. Use the commands show cdp neighbors for both operating systems to view neighbor information. The command show cdp interface type mod/port or show cdp port mod/port displays port-specific information about CDP.

Feature Example

This example shows a switch with the CDP timers altered so that the holdtime is 480 seconds and the update time is 120 seconds. It also shows CDP disabled for port 3/1 through 3/48 on the COS switch and Fast Ethernet ports 1 to 12 on an IOS switch.

An example of the COS configuration follows:

 Console (enable)> set cdp interval 120 Console (enable)> set cdp holdtime 480 Console (enable)> set cdp disable 3/1-48 

An example of the Supervisor IOS configuration follows:

 Switch(config)# cdp timer 120 Switch(config)# cdp holdtime 480 Switch(config)# interface fastethernet 0/1 Switch(config)# no cdp enable Switch(config)# interface fastethernet 0/2 Switch(config)# no cdp enable Switch(config)# interface fastethernet 0/3 Switch(config)# no cdp enable Switch(config)# interface fastethernet 0/4 Switch(config)# no cdp enable Switch(config)# interface fastethernet 0/5 Switch(config)# no cdp enable Switch(config)# interface fastethernet 0/6 Switch(config)# no cdp enable Switch(config)#end Switch#copy running-config startup-config 



Cisco Field Manual. Catalyst Switch Configuration
Cisco Field Manual. Catalyst Switch Configuration
ISBN: 1587050439
EAN: N/A
Year: 2001
Pages: 150

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net