Cisco Discovery Protocol(CDP) and Link Layer Dicovery Protocol(LLDP) in Data Link

The Cisco Discovery Protocol (CDP) and Link Layer Discovery Protocol (LLDP) are Layer 2 discovery protocols that enable network devices to share information about themselves with directly connected neighbors. These protocols are essential for network management, troubleshooting, and topology discovery.

CDP is a proprietary Cisco protocol, while LLDP is an open IEEE 802.1AB standard that works across multiple vendors. Both protocols operate at the data link layer and help administrators understand network topology without requiring higher-layer protocols.

How Discovery Protocols Work

Discovery protocols send periodic advertisements containing device information to directly connected neighbors. These messages are transmitted as multicast frames at Layer 2, making them independent of network layer protocols like IP.

Layer 2 Discovery Protocol Operation Switch A IP: 192.168.1.10 Model: 2960 Port: Gi0/1 Switch B IP: 192.168.1.20 Model: 3560 Port: Gi0/2 CDP/LLDP Advertisements Devices exchange information every 60 seconds (default) Information stored in neighbor table for 180 seconds

Cisco Discovery Protocol (CDP)

CDP is Cisco's proprietary Layer 2 protocol that works exclusively with Cisco devices. It operates on various data link technologies including Ethernet, Frame Relay, ATM, Token Ring, and PPP.

CDP Information Shared

  • Device identification Hostname, device model, and hardware capabilities

  • Network information IP addresses and interface details

  • Software version IOS version and platform information

  • Port information Local and remote port identifiers

CDP Commands

show cdp neighbors          # View neighbor summary
show cdp neighbors detail   # View detailed neighbor info
show cdp interface         # View CDP-enabled interfaces
cdp run                    # Enable CDP globally
cdp enable                 # Enable CDP on interface

Link Layer Discovery Protocol (LLDP)

LLDP is an IEEE 802.1AB standard protocol that provides vendor-neutral device discovery. Unlike CDP, LLDP works across multi-vendor environments and uses Type-Length-Value (TLV) format for information exchange.

LLDP Extensions

  • LLDP-MED Media Endpoint Discovery for VoIP phones and endpoints

  • DCBX Data Center Bridging Extension for storage networks

  • Power over Ethernet Power classification and management

CDP vs LLDP Comparison

Feature CDP LLDP
Standard Cisco Proprietary IEEE 802.1AB
Device Support Cisco devices only Multi-vendor
Default Timer 60 seconds 30 seconds
Hold Time 180 seconds 120 seconds
Information Format Cisco-specific fields TLV (Type-Length-Value)

Security Considerations

Both CDP and LLDP can pose security risks as they advertise detailed device information. Attackers can use this information for reconnaissance. Best practices include disabling these protocols on untrusted interfaces and monitoring for unauthorized devices.

Common Use Cases

  • Network documentation Automatic discovery of network topology

  • Troubleshooting Identifying misconfigurations and connectivity issues

  • Power management PoE device classification and power allocation

  • VLAN management Voice VLAN assignment for IP phones

Conclusion

CDP and LLDP are essential Layer 2 discovery protocols that enable automatic network topology discovery and device information sharing. While CDP is limited to Cisco environments, LLDP provides standardized multi-vendor support, making both protocols valuable tools for network management and troubleshooting.

Updated on: 2026-03-16T23:36:12+05:30

856 Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements