What is LLDP (Link Layer Discovery Protocol)?

LLDP (Link Layer Discovery Protocol) is a protocol that runs on the Layer 2 layer of OSI, designed to discover network devices such as switches and routers in local networks. In addition, this protocol, designed as an alternative to CDP, is defined in the IEEE 802.1AB document and performs sending, receiving, and managing with the agent providing communication between devices.

What is LLDP (Link Layer Discovery Protocol)?

What is LLDP Protocol?

For information exchange between devices in the network, a MAC frame transmitted with a broadcast destination address is only received by neighboring devices on the same network. This package structure contains the Chassis ID, Port ID, and TTL information and is called LLDPDU. This information consists of TLV (Type-Length-Value) fields, a format that shows the type, length, and value of each of the fields.

The information obtained with this protocol is not shared with the rest of the devices, so it is designed to work with SNMP and this information is stored in a MIB and can be obtained from a local or remote network via SNMP.

There is also an improved version called LLDPMED (Link Layer Discovery Protocol – Media Endpoint Discovery) to obtain information about devices that are not connected to the same network. In this way, information about network policies, device location, power management, inventory management, team capabilities, and network speed can be shared between devices that are not on the same network with LLDPMED.

Each device in the network has an LLDP Agent that manages its access to higher layers. This agent is responsible for receiving, sending, and managing packages.

One of the biggest usage areas of the Link Discovery protocol in computer networks is to determine VoIP systems. Additionally, if only Cisco-branded devices are not available on a network, then CDP will not be very convenient. Because if there are both Cisco devices and 3rd party devices produced by other manufacturers in the network environment, LLDP will be much more useful in this case.

How Does It Work?

A device that supports this protocol on the network frequently sends messages to its neighbors at the port of the switch to which it is connected to identify itself and provide network-related information.

The obtained information is stored in a data table known as MIB (Management Information Base) and the information in this database can be read via SNMP.

Therefore, this database contains the device’s system name and properties, port name, IP management address, and other network information. As a result, the entire logical topology of the network can be obtained by reading this database with SNMP.

LLDPMED Working Logic

This updated version exchanges VoIP related information from network devices and other devices, thus simplifying VoIP deployment. This protocol performs the following operations in order;

  1. The switch transmits data regarding the power capacity of its ports, virtual LANs for audio systems, DiffServ Code Point, and location data.
  2. IP telephony broadcasts power requirements and priorities, VLANs configured for audio systems, DiffServe Code Point, and its own information.
  3. The network management system requests detailed information of IP phones from the Switch to create topological maps of the voice and data infrastructure.


Cisco Proprietary
IEEE 802.1AB
Operation Level
Data Link Layer
Data Link Layer
Highly Adjustable
Active by Default
Active by Default

How to Enable and Configure LLDP on Cisco Router or Cisco Switch

The link-layer discovery protocol is not enabled by default on devices such as CDP, so it must be manually enabled. To enable the Link Discovery protocol on a Router and Switch on the GNS3 network simulator program, simply execute the lldp run command in config mode at the CLI prompt.

If you want to disable this service on a device in the network, execute the no lldp run command in the config mode of the relevant device.

Let’s examine the commands now;

   show lldp (Inactive)

% LLDP is not enabled

   lldp run

L2_B_SW#conf t
L2_B_SW(config)#lldp run

   show lldp (Active)

Global Information:
    Status: ACTIVE
    LLDP advertisements are sent every 30 seconds
    LLDP hold time advertised is 120 seconds
    LLDP interface reinitialisation delay is 2 seconds

   show lldp neighbors

Capability codes:
    (R) Router, (B) Bridge, (T) Telephone, (C) DOCSIS Cable Device
    (W) WLAN Access Point, (P) Repeater, (S) Station, (O) Other

Device ID           Local Intf     Hold-time  Capability      Port ID
L2_A_SW             Gi0/0          120        R               Gi0/0

Total entries displayed: 1


   no lldp transmit

L2_B_SW(config)#interface gigabitEthernet 0/0
L2_B_SW(config-if)#lldp ?
  med-tlv-select  Selection of LLDPMED TLVs to send
  receive         Enable LLDP reception on interface
  tlv-select      Selection of LLDP TLVs to send
  transmit        Enable LLDP transmission on interface

L2_B_SW(config-if)#no lldp transmit 

When the no lldp transmit command is executed on the GigabitEthernet0/0 interface of L2_B_SW connected to L2_A_SW, the forwarding of packets over that interface is disabled, and no results are listed when the show lldp neighbors command is executed on L2_A_SW.

The L2_A_SW command output will be as follows;

Capability codes:
    (R) Router, (B) Bridge, (T) Telephone, (C) DOCSIS Cable Device
    (W) WLAN Access Point, (P) Repeater, (S) Station, (O) Other

Device ID           Local Intf     Hold-time  Capability      Port ID

Total entries displayed: 0

   show lldp neighbors detail (L2_B_SW)

Local Intf: Gi0/0
Chassis id: 0ce6.486e.b400
Port id: Gi0/0
Port Description: GigabitEthernet0/0
System Name: L2_A_SW

System Description: 
Cisco IOS Software, vios_l2 Software (vios_l2-ADVENTERPRISEK9-M), Version 15.0(4
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2014 by Cisco Syst

Time remaining: 87 seconds
System Capabilities: B,R
Enabled Capabilities: R
Management Addresses - not advertised
Auto Negotiation - not supported
Physical media capabilities - not advertised
Media Attachment Unit type - not advertised
Vlan ID: - not advertised

Total entries displayed: 1


   show lldp traffic

Traffic statistics:
    Total frames out: 34
    Total entries aged: 0
    Total frames in: 12
    Total frames received in error: 0
    Total frames discarded: 0
    Total TLVs discarded: 0
    Total TLVs unrecognized: 0

   Related Articles

What is EGP?
What is IGP?
What is NetFlow?
What is SSL?
What is TLS?

Add a Comment

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