Configuring LLDP, and LLDP-MED
This chapter describes how to configure the Link Layer Discovery Protocol (LLDP) and LLDP Media Endpoint Discovery (LLDP-MED) on the Catalyst 4500 series switch.
Note
For complete syntax and usage information for the commands used in this chapter, see the command reference for this release and the "System Management Commands" section in the Cisco IOS Configuration Fundamentals Command Reference, Release 12.2.
This chapter consists of these sections:
•
About LLDP and LLDP-MED
•
Configuring LLDP and LLDP-MED
•
Cisco IOS Carries Ethernet Features in Cisco IOS XE 3.1.0 SG
About LLDP and LLDP-MED
This section contains this conceptual information:
•
Understanding LLDP
•
Understanding LLDP-MED
Understanding LLDP
The Cisco Discovery Protocol (CDP) is a device discovery protocol that runs over Layer 2 (the data link layer) on all Cisco-manufactured devices (routers, bridges, access servers, and switches). CDP allows network management applications to automatically discover and learn about other Cisco devices connected to the network.
To support non-Cisco devices and to allow for interoperability between other devices, the switch supports the IEEE 802.1AB LLDP. LLDP is a neighbor discovery protocol that is used for network devices to advertise information about themselves to other devices on the network. This protocol runs over the data-link layer, which allows two systems running different network layer protocols to learn about each other.
LLDP supports a set of attributes that it uses to discover neighbor devices. These attributes contain type, length, and value descriptions and are referred to as TLVs. LLDP supported devices can use TLVs to receive and send information to their neighbors. Details such as configuration information, device capabilities, and device identity can be advertised using this protocol.
The switch supports the following basic management TLVs, which are optional:
•
Port description TLV
•
System name TLV
•
System description TLV
•
System capabilities TLV
•
Management address TLV
•
Power Management TLV
These organizationally specific LLDP TLVs are also advertised to support LLDP-MED.
•
Port VLAN ID TLV ((IEEE 802.1 organizationally specific TLVs)
•
MAC/PHY configuration/status TLV(IEEE 802.3 organizationally specific TLVs)
Understanding LLDP-MED
LLDP for Media Endpoint Devices (LLDP-MED) is an extension to LLDP that operates between endpoint devices such as IP phones and network devices such as switches. It specifically provides support for voice over IP (VoIP) applications and provides additional TLVs for capabilities discovery, network policy, Power over Ethernet, inventory management, and location information. By default, all LLDP-MED TLVs are enabled.
LLDP-MED supports these TLVs:
•
LLDP-MED capabilities TLV
Allows LLDP-MED endpoints to determine the capabilities that the connected device supports and what capabilities the device has enabled.
•
Network policy TLV
Allows both network connectivity devices and endpoints to advertise VLAN configurations and associated Layer 2 and Layer 3 attributes for the specific application on that port. For example, the switch can notify a phone of the VLAN number that it should use. The phone can connect into any switch, obtain its VLAN number, and then start communicating with the call control
•
Power management TLV
Enables advanced power management between LLDP-MED endpoint and network connectivity devices. Allows switches and phones to convey power information, such as how the device is powered, power priority, and how much power the device needs.
Note
Power Management TLV only exchanges power information; it does not perform power negotiation, which is handled by CDP.
•
Inventory management TLV
Allows an endpoint to send detailed inventory information about itself to the switch, including information hardware revision, firmware version, software version, serial number, manufacturer name, model name, and asset ID TLV.
•
Location TLV
Provides location information from the switch to the endpoint device. The location TLV can send this information:
–
Civic location information
Provides the civic address information and postal information. Examples of civic location information are street address, road name, and postal community name information.
–
ELIN location information
Provides the location information for a caller. The location is determined by the Emergency location identifier number (ELIN), which is a phone number that routes an emergency call to the local public safety answering point (PSAP) and which the PSAP can use to call back the emergency caller.
Note
A switch cannot send LLDP and LLDP-MED simultaneously to an end-point device. By default, a network device sends only LLDP packets until it receives LLDP-MED packets from an end-point device. The network device then sends LLDP-MED packets until it receives only LLDP packets.
Configuring LLDP and LLDP-MED
This section contains this configuration information:
•
Default LLDP Configuration
•
Configuring LLDP Characteristics
•
Disabling and Enabling LLDP Globally
•
Disabling and Enabling LLDP on an Interface
•
Configuring LLDP-MED TLVs
•
Configuring LLDP Power Negotiation
•
Configuring LLDP and Location TLV
•
Monitoring and Maintaining LLDP and LLDP-MED
Default LLDP Configuration
Table 23-1 shows the default LLDP configuration. To change the default settings, use the LLDP global configuration and LLDP interface configuration commands.
Table 23-1 Default LLDP Configuration
|
|
LLDP global state |
Disabled |
LLDP holdtime (before discarding) |
120 seconds |
LLDP timer (packet update frequency) |
30 seconds |
LLDP reinitialization delay |
2 seconds |
LLDP tlv-select |
Enabled to send and receive all TLVs. |
LLDP interface state |
Enabled |
LLDP receive |
Enabled |
LLDP transmit |
Enabled |
LLDP med-tlv-select |
Enabled to send all LLDP-MED TLVs |
Configuring LLDP Characteristics
You can configure the frequency of LLDP updates, the amount of time to hold the information before discarding it, the initialization delay time. You can also select the LLDP and LLDP-MED TLVs for sending and receiving. The location service feature is available only when the switch is running the cryptographic (encrypted) software image.
To configure these characteristics, perform this task:
Note
Steps 2 through 5 can be performed in any order.
|
|
|
Step 1 |
Switch# configure terminal
|
Enters global configuration mode. |
Step 2 |
Switch(config)# lldp holdtime
seconds
|
(Optional) Specifies the amount of time a receiving device should hold the information sent by your device before discarding it. The range is 0 to 65535 seconds; the default is 120 seconds. |
Step 3 |
Switch(config)# lldp reinit
|
(Optional) Specific the delay time in seconds for LLDP to initialize on any interface. The range is 2 to 5 seconds; the default is 2 seconds. |
Step 4 |
Switch(config)# lldp timer seconds
|
(Optional) Sets the transmission frequency of LLDP updates in seconds. The range is 5 to 65534 seconds; the default is 30 seconds. |
Step 5 |
Switch(config)# lldp tlv-select
|
(Optional) Specifies the LLDP TLVs to send or receive. |
Step 6 |
Switch(config)# copy running-config
startup-config
|
Saves your entries in the configuration file. |
Step 7 |
Switch(config)# lldp med-tlv-select
|
(Optional) Specifies the LLDP-MED TLVs to send or receive. |
Note
Use the no form of each of the LLDP commands to return to the default setting.
This example shows how to configure a holdtime of 120 second, a delay time of 2 seconds and an update frequency of 30:
Switch# configure terminal
Switch(config)# lldp holdtime 120
Switch(config)# lldp reinit 2
Switch(config)# lldp timer 30
This example shows how to transmit only LLDP packets:
switch# configure terminal
siwtch(config)# no lldp receive
If you want to receive LLDP packets again, do the following:
switch# configure terminal
siwtch(config)# lldp receive
For additional LLDP show commands, see the "Monitoring and Maintaining LLDP and LLDP-MED" section.
Disabling and Enabling LLDP Globally
Note
LLDP is disabled by default.
To disable LLDP globally, do the following:
|
|
|
Step 1 |
Switch# configure terminal
|
Enters global configuration mode. |
Step 2 |
Switch(config)# no lldp run
|
Disables LLDP. |
Step 3 |
|
Returns to privileged EXEC mode. |
To enable LLDP once it has been disabled, do the following:
|
|
|
Step 1 |
Switch# configure terminal
|
Enters global configuration mode. |
Step 2 |
|
Enables LLDP. |
Step 3 |
|
Returns to privileged EXEC mode. |
This example shows how to globally disable LLDP.
Switch# configure terminal
Switch(config)# no lldp run
This example shows how to globally enable LLDP.
Switch# configure terminal
Disabling and Enabling LLDP on an Interface
LLDP is disabled globally on all supported interfaces. You must enable LLDP globally to allow a device to send LLDP packets. However, no changes are required at the interface level.
You can configure the interface to selectively not to send and receive LLDP packets with the
no lldp transmit and no lldp receive commands.
Note
If the interface is configured as a tunnel port, LLDP is automatically disabled.
To disable LLDP on an interface, perform this task:
|
|
|
Step 1 |
Switch# configure terminal
|
Enters global configuration mode. |
Step 2 |
Switch(config)# interface interface-id
|
Specifies the interface on which you are disabling LLDP, and enter interface configuration mode. |
Step 3 |
Switch(config)# no lldp transmit
|
Disallows sending LLDP packets on the interface. |
Step 4 |
Switch(config)# no lldp receive
|
Disallows receiving LLDP packets on the interface. |
Step 5 |
|
Returns to privileged EXEC mode. |
Step 6 |
Switch(config)# copy running-config
startup-config
|
Saves your entries in the configuration file. |
To enable LLDP on an interface once it has been disabled, perform this task:
|
|
|
Step 1 |
Switch# configure terminal
|
Enters global configuration mode. |
Step 2 |
Switch(config)# interface interface-id
|
Specifies the interface on which you are enabling LLDP, and enter interface configuration mode. |
Step 3 |
Switch(config)# lldp transmit
|
Sends LLDP packets on the interface. |
Step 4 |
Switch(config)# lldp receive
|
Receives LLDP packets on the interface. |
Step 5 |
|
Returns to privileged EXEC mode. |
Step 6 |
Switch# copy running-config
startup-config
|
Saves your entries in the configuration file. |
This example shows how to enable LLDP on an interface.
Switch# configure terminal
Switch(config)# interface GigabitEthernet 1/1
Switch(config-if)# lldp transmit
Switch(config-if)# lldp receive
Configuring LLDP-MED TLVs
By default, the switch only sends LLDP packets until it receives LLDP-MED packets from the end device. The switch continues to send LLDP-MED packets until it only receives LLDP packets.
By using the lldp interface configuration command, you can configure the interface not to send the TLVs listed in Table 23-2.
Table 23-2 LLDP-MED TLVs
|
|
inventory-management |
LLDP-MED inventory management TLV |
location |
LLDP-MED location TLV |
network-policy |
LLDP-MED network policy TLV |
power-management |
LLDP-MED power management TLV |
To disable a TLV on an interface, perform this task:
|
|
|
Step 1 |
Switch# configure terminal
|
Enters global configuration mode. |
Step 2 |
Switch(config)# interface interface-id
|
Specifies the interface on which you are configuring a LLDP-MED TLV, and enter interface configuration mode. |
Step 3 |
Switch(config-if)# no lldp
med-tlv-select tlv
|
Specifies the TLV to disable. |
Step 4 |
|
Returns to privileged EXEC mode. |
Step 5 |
Switch# copy running-config
startup-config
|
(Optional) Saves your entries in the configuration file. |
To enable a TLV on an interface, perform this task:
|
|
|
Step 1 |
Switch# configure terminal
|
Enters global configuration mode. |
Step 2 |
Switch(config)# interface interface-id
|
Specifies the interface on which you are configuring an LLDP-MED TLV, and enter interface configuration mode. |
Step 3 |
Switch(config-if)# lldp med-tlv-select
tlv
|
Specifies the TLV to enable. |
Step 4 |
|
Returns to privileged EXEC mode. |
Step 5 |
Switch# copy running-config
startup-config
|
(Optional) Saves your entries in the configuration file. |
This example shows how to enable a TLV on an interface when it has been disabled.
Switch# configure terminal
Switch(config)# interface GigabitEthernet0/1
Switch(config-if)# lldp med-tlv-select inventory management
Configuring LLDP Power Negotiation
Starting with Cisco IOS Release 12.2(54)SG, Catalyst 4500 series switches can perform inline power negotiation using LLDP as specified in the IEEE 802.3at standard. (The LLDP TLV used is
DTE Power-via-MDI TLV.) With this feature, inline powered devices based on the IEEE standard can be powered in the PoE+ power range (12.95W to 25.5W at the device end) by the switch on PoE+ supported modules.
Note
To verify inline power utilization negotiated by using LLDP using the LLDP-MED TLV, use the
show lldp neighbors detail command. To verify inline power utilization negotiated by using the IEEE 802.3at TLV, use the show power inline interface detail command. The show power inline interface detail command does not display power negotiated with LLDP.
Note
When an inline powered device that performs power negotiation using multiple protocols (CDP/LLDP 802.3at/LLDP-MED) is connected to a switch, the switch "locks" to the first protocol packet (CDP or LLDP) that contains the power negotiation TLV. The LLDP 802.3at power negotiation TLV overrides the LLDP-MED power negotiation TLV if both are received by the switch. If the administrator needs to use any single protocol for power negotiation each time, he needs to administratively disable the other power negotiation protocols on the switch interface or the end device.
To enable LLDP power negotiation, perform this task:
|
|
|
Step 1 |
Switch# configure terminal
|
Enters global configuration mode. |
Step 2 |
Switch(config)# interface interface-id
|
Specifies the interface on which you are configuring LLDP power negotiation. |
Step 3 |
Switch(config-if)# lldp tlv-select
power-management
|
Enables LLDP power negotiation. |
Step 4 |
|
Returns to privileged EXEC mode. |
Step 5 |
Switch# copy running-config
startup-config
|
(Optional) Saves your entries in the configuration file. |
This example shows how to enable LLDP power negotiation on interface Gigabit Ethernet 3/1:
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)# int gi 3/1
Switch(config-if)# lldp tlv-select power-management
Configuring LLDP and Location TLV
To configure location information for an end-point and to apply it to an interface, perform this task:
|
|
|
Step 1 |
Switch# configure terminal
|
Enters global configuration mode. |
Step 2 |
Switch(config)# location {admin-tag
string | civic-location identifier id |
elin-location string identifier id}
|
Specifies the location information for an endpoint. • admin-tag—Specify an administrative tag or site information. • civic-location—Specify civic location information. Note The civic location identifier in the LLDP-MED TLV is limited to 250 bytes or less. To avoid receiving error messages regarding available buffer space during switch configuration, never allow the total length of all civic location information specified for each civic-location identifier to exceed 250 bytes. • elin-location—Specify emergency location information (ELIN). • identifier id—Specify the ID for the civic location. • string—specify the site or location information in alphanumeric format. |
Step 3 |
Switch(config-civic)# exit
|
Returns to global configuration mode. |
Step 4 |
Switch(config)# interface interface-id
|
Specifies the interface on which you are configuring the location information, and enter interface configuration mode. |
Step 5 |
Switch(config-if)# location
{additional-location-information word |
civic-location-id id | elin-location-id
id}
|
Enters location information for an interface: additional-location-information—Specifies additional information for a location or place. civic-location-id—Specifies global civic location information for an interface. elin-location-id—Specifies emergency location information for an interface. id—Specifies the ID for the civic location or the ELIN location. The ID range is 1 to 4095. word—Specifies a word or phrase that provides additional location information. |
Step 6 |
|
Returns to privileged EXEC mode. |
Step 7 |
|
Verifies the configuration. |
Step 8 |
Switch# copy running-config
startup-config
|
(Optional) Saves your entries in the configuration file. |
Use the no form of each command to return to the default setting.
This example shows how to configure civic location information on the switch:
Switch# configure terminal
Switch(config)# location civic-location identifier 1
Switch(config-civic)# number 3550
Switch(config-civic)# primary-road-name "Cisco Way"
Switch(config-civic)# city "San Jose"
Switch(config-civic)# state CA
Switch(config-civic)# building 19
Switch(config-civic)# room C6
Switch(config-civic)# county "Santa Clara"
Switch(config-civic)# country US
Switch(config-civic)# end
Monitoring and Maintaining LLDP and LLDP-MED
To monitor and maintain LLDP and LLDP-MED on your device, perform one or more of the following commands in privileged EXEC mode:
|
|
|
Resets the traffic and error counters to zero. |
|
Deletes the LLDP table of information about neighbors. |
|
Displays global information, such as frequency of transmissions, the holdtime for packets being sent, and the delay time for LLDP to initialize on an interface. |
show lldp entry entry-name
|
Displays information about a specific neighbor. You can enter an asterisk (*) to display all neighbors, or you can enter the name of the neighbor about which you want information. |
|
Displays LLDP computational errors and overflows. |
show lldp interface [interface-id]
|
Displays information about interfaces where LLDP is enabled. You can limit the display to the interface about which you want information. |
show lldp neighbors [interface-id]
[detail]
|
Displays information about neighbors, including device type, interface type and number, holdtime settings, capabilities, and port ID. You can limit the display to neighbors of a specific interface or expand the display to provide more detailed information. |
|
Displays LLDP counters, including the number of packets sent and received, number of packets discarded, and number of unrecognized TLVs. |
|
Displays the location information for an endpoint. |
show power inline interface [detail]
|
Displays detailed information on the PoE status for the interface |
show power inline module mod
[detail]
|
Displays detailed information on the PoE consumption for the specified module. |
Cisco IOS Carries Ethernet Features in Cisco IOS XE 3.1.0 SG
This section provides a list of High Availability software features that are supported in Cisco IOS XE 3.1.0SG. Links to the feature documentation are included.
Feature guides may contain information about more than one feature. To find information about a specific feature within a feature guide, see the Feature Information table at the end of the guide.
Feature guides document features that are supported on many different software releases and platforms. Your Cisco software release or platform may not support all the features documented in a feature guide. See the Feature Information table at the end of the feature guide for information about which features in that guide are supported in your software release. Use Cisco Feature Navigator to find information about platform support and Cisco software image support. To access Cisco Feature Navigator, go to http://www.cisco.com/go/cfn. An account on Cisco.com is not required.
ANSI TIA-1057 LLDP-MED Support and IEEE 802.1ab LLDP (Link Layer Discovery Protocol)
http://www.cisco.com/en/US/docs/ios/cether/configuration/guide/ce_lldp-med.html