2
Overview
Introduction to UDLD
Unidirectional Link Detection (UDLD) is a Cisco-proprietary protocol that detects unidirectional links.
UDLD is a light-weight protocol that can be used to detect and disable one-way connections before they create
dangerous situations such as “spanning tree” loops or other protocol malfunctions.
In a network that has an extensive fiber cabling plant, problems may arise when incorrect patching leads to a switch
port having its RX fiber strand connected to one switch port and its TX fiber strand connected to another. In these
cases, a port may be deemed active if it is receiving an optical signal on its RX strand. However, the problem is that
this link does not provide a valid communication path at Layer 2 (and above).
If this scenario of wrongly connected fiber strands is applied to multiple ports to create a fiber loop, each device in
the loop could directly send packets to a neighbor but would not be able to receive from the same device to which it
is sending to. Albeit the above scenario is rather extreme, it exemplifies how the lack of mutual identification of the
neighbors can bring protocols to the wrong assumption that during a transmission the sender and the receiver at the
other end of the link match.
Another equally dangerous incorrect assumption is that the lack of reception of protocol messages on a port
unmistakably indicates the absence of transmitting protocol entities at the other end of the link.
The UDLD protocol was implemented to help correct certain assumptions made by other protocols and in particular to
help the spanning tree protocol to function properly so as to avoid the creation of dangerous Layer 2 loops.
UDLD protocol architecture
UDLD uses two basic mechanisms:
• It advertises a port’s identity and learns about its neighbors on a specific LAN segment; it keeps the acquired
information on the neighbors in a cache table.
• It sends a train of echo messages in certain circumstances that require fast notifications or fast resynchronization of
the cached information.
Due to this, the algorithm run by UDLD requires that all the devices connected to the same LAN segment run the
protocol, so that potential misconfiguration is detected and prompt corrective action is taken.
UDLD periodically sends “hello” packets (also called “advertisements” or “probes”) on every active interface to keep
each device informed of its neighbors. When a hello message is received, it is cached and kept in memory for a defined
time interval, called “hold time” or “time-to-live”, after which the cache entry is considered stale and is aged out.
If a new hello message is received when a correspondent old cache entry has not been aged out yet, then the old
entry is dropped and is replaced by the new one with a reset time-to-live timer.
The echoing mechanism is the base of UDLD’s detection algorithm: whenever a UDLD device learns about a new
neighbor or receives a resynchronization request from an out-of-synch neighbor, it (re)starts the detection process on
its side of the connection and sends N-echo messages in reply. (This mechanism implicitly assumes that N-packets are
sufficient to get through a link and reach the other end, even though some of them might get dropped during the
transmission.) Since this behavior must be the similar among all the neighbors, the sender of the echoes expects to
receive after some time an echo in reply. If the detection process ends without the proper echo information being
received, under specific conditions the link is considered to be unidirectional.
评论1
最新资源