UDLD protocol allows the devices connected through fiber optic or copper (for
example, Category 5 cabling) Ethernet cables that are connected to the LAN
ports to monitor the physical configuration of the cables and detect whether a
unidirectional link exists. When a unidirectional link is detected, the UDLD
shuts down the affected LAN port and alerts the corresponding user, because
unidirectional links cause a variety of problems, including spanning tree
UDLD is a Layer 2
protocol that works with the Layer 1 protocols to determine the physical status
of a link. In Layer 1, auto negotiation takes care of physical signaling and
fault detection. UDLD performs tasks that auto negotiation cannot perform, such
as detecting the identities of neighbors and shutting down misconnected LAN
ports. When you enable both auto negotiation and UDLD, the Layer 1 and Layer 2
detections work together to prevent physical and logical unidirectional
connections and the malfunctioning of other protocols.
A unidirectional link
occurs whenever the traffic transmitted by a local device over a link is
received by a neighbor, but traffic transmitted from the neighbor is not
received by the local device. If one of the fiber strands in a pair is
disconnected, the link does not stay up as long as the auto negotiation is
active. In such a scenario, the logical link is undetermined, and the UDLD does
not take any action. If both the fibers are working normally in Layer 1, the
UDLD in Layer 2 determines whether those fibers are connected correctly and
whether the traffic is flowing bidirectionally between the correct neighbors.
This check cannot be performed by auto negotiation because auto negotiation
operates in Layer 1.
periodically transmits the UDLD packets to the neighbor devices on LAN ports
where UDLD is enabled. If the packets are echoed back within a specific
timeframe and they are lacking a specific acknowledgment (echo), the link is
flagged as unidirectional and the LAN port is shut down. Devices on both ends
of the link must support UDLD for the protocol to successfully identify and
disable the unidirectional links.
UDLD detects and disables unidirectional links on Ethernet fiber and
copper interfaces due to miswiring or malfunctioning of the interfaces.
UDLD is disabled by
default on all ports to avoid sending unnecessary traffic.
To configure fibre-optic interfaces, enable the
udld command at the global level. For copper
interfaces, enable the
command at the interface level.
The figure displays
the UDLD mechanism.
Figure 1. Unidirectional
UDLD supports two modes of operation: normal (the default) and
aggressive. In normal mode, UDLD can detect unidirectional links due to
misconnected interfaces on fiber-optic connections. In aggressive mode, UDLD
can also detect unidirectional links due to one-way traffic on fiber-optic and
twisted-pair links and to misconnected interfaces on fiber-optic links.