|
|
This chapter describes how to configure the UniDirectional Link Detection (UDLD) protocol on the Catalyst enterprise LAN switches.
This chapter consists of these sections:
The UDLD protocol allows devices connected through fiber-optic or copper (for example, Category 5 cabling) Ethernet cables to monitor the physical configuration of the cables and detect when a unidirectional link exists. When a unidirectional link is detected, UDLD shuts down the affected port and alerts the user.
A unidirectional link occurs whenever traffic transmitted by the local device over a link is received by the neighbor, but traffic transmitted from the neighbor is not received by the local device. Unidirectional links can cause a variety of problems, including spanning-tree topology loops.
The switch periodically transmits UDLD packets to neighbor devices on ports with UDLD enabled. If the packets are not echoed back to the sender, the link is flagged as unidirectional and the port is shut down. Devices on both ends of the link must support UDLD in order for the protocol to successfully identify and disable unidirectional links.
Figure 24-1 shows an example of a unidirectional link condition. Switch B successfully receives traffic from Switch A on the port. However, Switch A does not receive traffic from Switch B on the same port. UDLD detects the problem and disables the port.

UDLD requires the following hardware and software:
Table 24-1 shows the default UDLD configuration.
| Feature | Default Value |
|---|---|
UDLD global enable state | Globally disabled |
UDLD per-port enable state |
|
These sections describe how to configure UDLD:
You must enable UDLD globally before any port can use UDLD.
To enable UDLD globally on the switch, perform this task in privileged mode:
| Task | Command |
|---|---|
Step 1 Enable UDLD globally on the switch. | set udld enable |
Step 2 Verify the configuration. | show udld |
This example shows how to enable UDLD globally and verify the configuration:
Console> (enable) set udld enable UDLD enabled globally Console> (enable) show udld UDLD : enabled Console> (enable)
To enable UDLD on individual ports, perform this task in privileged mode:
| Task | Command |
|---|---|
Step 1 Enable UDLD on a specific port. | set udld enable mod_num/port_num |
Step 2 Verify the configuration. | show udld port [mod_num[/port_num]] |
This example shows how to enable UDLD on port 4/1 and verify the configuration:
Console> (enable) set udld enable 4/1 UDLD enabled on port 4/1. Console> (enable) show udld port 4/1 UDLD : enabled Port Admin Status Link State -------- ------------ ---------------- 4/1 enabled bidirectional Console> (enable)
To disable UDLD on individual ports, perform this task in privileged mode:
| Task | Command |
|---|---|
Step 1 Disable UDLD on a specific port. | set udld disable mod_num/port_num |
Step 2 Verify the configuration. | show udld port [mod_num[/port_num]] |
This example shows how to disable UDLD on port 4/1:
Console> (enable) set udld disable 4/1 UDLD disabled on port 4/1. Console> (enable)
To disable UDLD globally on the switch, perform this task in privileged mode:
| Task | Command |
|---|---|
Step 1 Disable UDLD globally on the switch. | set udld disable |
Step 2 Verify the configuration. | show udld |
This example shows how to disable UDLD globally on the switch:
Console> (enable) set udld disable UDLD disabled globally Console> (enable)
To display the UDLD enable state, perform this task in privileged mode:
| Task | Command |
|---|---|
Display the UDLD enable state. | show udld |
This example shows how to display the UDLD enable state:
Console> (enable) show udld UDLD : enabled Console> (enable)
To display UDLD configuration for a module or port, perform this task in privileged mode:
| Task | Command |
|---|---|
Display the UDLD configuration for a module or port. | show udld port [mod_num[/port_num]] |
This example shows how to display the UDLD configuration for ports on module 4:
Console> (enable) show udld port 4 UDLD : enabled Port Admin Status Link State -------- ------------ ---------------- 4/1 disabled not applicable 4/2 disabled not applicable 4/3 disabled not applicable 4/4 disabled not applicable 4/5 enabled undetermined 4/6 enabled undetermined 4/7 enabled bidirectional 4/8 enabled bidirectional 4/9 enabled bidirectional 4/10 enabled bidirectional 4/11 enabled shutdown 4/12 enabled shutdown Console> (enable)
The link state is "undetermined" in these situations:
The link state is "bidirectional" when the local and neighbor ports are successfully exchanging UDLD packets. The link state is "shutdown" when a unidirectional link is detected and the port has been shut down.
![]()
![]()
![]()
![]()
![]()
![]()
![]()
Posted: Fri Oct 1 13:19:18 PDT 1999
Copyright 1989-1999©Cisco Systems Inc.