- Table of Contents
- Related Documents
-
Title | Size | Download |
---|---|---|
01-S12500_DLDP_Configuration_Examples | 140.67 KB |
Contents
Example: Automatically shutting down unidirectional links
Configuration restrictions and guidelines
Example: Manually shutting down unidirectional links
Configuration restrictions and guidelines
Introduction
This document provides Device Link Detection Protocol (DLDP) configuration examples.
DLDP detects whether the fiber link or twisted-pair link is correctly connected at the link layer, and whether the two ends can exchange packets correctly. When DLDP detects unidirectional links, it can automatically shut down the faulty port or users can manually shut down the faulty port to avoid network problems such as error forwarding and loops. DLDP cooperates with physical layer protocols to monitor link status and avoid physical and logical unidirectional links.
Prerequisites
The configuration examples in this document were created and verified in a lab environment, and all the devices were started with the factory default configuration. When you are working on a live network, make sure you understand the potential impact of every command on your network.
This document assumes that you have basic knowledge of DLDP.
Example: Automatically shutting down unidirectional links
Network requirements
As shown in Figure 1, Device A and Device B are connected with two fiber pairs.
Configure DLDP to automatically shut down the faulty port upon detecting a unidirectional link, and automatically bring up the port after you clear the fault.
Requirements analysis
In this example, the unidirectional link might be caused by cross-connected fiber, connectionless fiber, or broken fiber. To enable DLDP to successfully detect the unidirectional link, configure DLDP to operate in enhanced mode.
To enable DLDP to automatically shut down the faulty port upon detecting a unidirectional link, set the port shutdown mode to auto (the default setting).
Software version used
This configuration example was created and verified on S12500-CMW520-R1825P01.
Configuration restrictions and guidelines
When you configure DLDP to automatically shut down unidirectional links, follow these restrictions and guidelines:
· DLDP is available only for Ethernet ports.
· To correctly configure DLDP, first enable DLDP globally, and then enable it on each port.
· For DLDP to operate correctly, configure the same forced speed and full duplex mode on both ends.
· DLDP can detect unidirectional links only after all links are physically connected. Before enabling DLDP, make sure optical fibers or copper twisted pairs are connected.
· For DLDP to work correctly, enable DLDP on both ends, and make sure the following settings are consistent:
¡ Interval for sending Advertisement packets.
¡ DLDP authentication mode.
¡ Password.
Configuration procedures
Configuring Device A
# Enable DLDP globally.
<DeviceA> system-view
[DeviceA] dldp enable
# Configure GigabitEthernet 2/0/1 to operate in full duplex mode, configure the port rate as 1000 Mbps, and enable DLDP on the port.
[DeviceA] interface gigabitethernet 2/0/1
[DeviceA-GigabitEthernet2/0/1] undo shutdown
[DeviceA-GigabitEthernet2/0/1] duplex full
[DeviceA-GigabitEthernet2/0/1] speed 1000
[DeviceA-GigabitEthernet2/0/1] dldp enable
[DeviceA-GigabitEthernet2/0/1] quit
# Configure GigabitEthernet 2/0/2 to operate in full duplex mode, configure the port rate as 1000 Mbps, and enable DLDP on the port.
[DeviceA] interface gigabitethernet 2/0/2
[DeviceA-GigabitEthernet2/0/2] undo shutdown
[DeviceA-GigabitEthernet2/0/2] duplex full
[DeviceA-GigabitEthernet2/0/2] speed 1000
[DeviceA-GigabitEthernet2/0/2] dldp enable
[DeviceA-GigabitEthernet2/0/2] quit
# Set the DLDP mode to enhanced.
[DeviceA] dldp work-mode enhance
# Set the port shutdown mode to auto.
[DeviceA] dldp unidirectional-shutdown auto
Configuring Device B
# Enable DLDP globally.
<DeviceB> system-view
[DeviceB] dldp enable
# Configure GigabitEthernet 2/0/1 to operate in full duplex mode, configure the port rate as 1000 Mbps, and enable DLDP on the port.
[DeviceB] interface gigabitethernet 2/0/1
[DeviceB-GigabitEthernet2/0/1] undo shutdown
[DeviceB-GigabitEthernet2/0/1] duplex full
[DeviceB-GigabitEthernet2/0/1] speed 1000
[DeviceB-GigabitEthernet2/0/1] dldp enable
[DeviceB-GigabitEthernet2/0/1] quit
# Configure GigabitEthernet 2/0/2 to operate in full duplex mode, configure the port rate as 1000 Mbps, and enable DLDP on the port.
[DeviceB] interface gigabitethernet 2/0/2
[DeviceB-GigabitEthernet2/0/2] undo shutdown
[DeviceB-GigabitEthernet2/0/2] duplex full
[DeviceB-GigabitEthernet2/0/2] speed 1000
[DeviceB-GigabitEthernet2/0/2] dldp enable
[DeviceB-GigabitEthernet2/0/2] quit
# Set the DLDP mode to enhanced.
[DeviceB] dldp work-mode enhance
# Set the port shutdown mode to auto.
[DeviceB] dldp unidirectional-shutdown auto
Verifying the configuration
After the configurations are complete, you can use the display dldp command to display the DLDP configuration information on ports.
# Display the DLDP configuration information on all the DLDP-enabled ports of Device A.
[DeviceA] display dldp
DLDP global status : enable
DLDP interval : 5s
DLDP work-mode : enhance
DLDP authentication-mode : none
DLDP unidirectional-shutdown : auto
DLDP delaydown-timer : 1s
The number of enabled ports is 2.
Interface GigabitEthernet2/0/1
DLDP port state : advertisement
DLDP link state : up
The neighbor number of the port is 1.
Neighbor mac address : 0023-8956-3600
Neighbor port index : 59
Neighbor state : two way
Neighbor aged time : 11
Interface GigabitEthernet2/0/2
DLDP port state : advertisement
DLDP link state : up
The neighbor number of the port is 1.
Neighbor mac address : 0023-8956-3600
Neighbor port index : 60
Neighbor state : two way
Neighbor aged time : 12
The output shows that both GigabitEthernet 2/0/1 and GigabitEthernet 2/0/2 are in Advertisement state, which means both links are bidirectional.
# Enable system information monitoring on Device A, and enable the display of log and trap information.
[DeviceA] quit
<DeviceA> terminal monitor
<DeviceA> terminal logging
<DeviceA> terminal trapping
The following log and trap information is displayed on Device A:
<DeviceA>
#Jan 18 17:36:18:798 2010 DeviceA DLDP/1/TrapOfUnidirectional: -Slot=2; Trap 1.3.6.1.4.1.25506.2.43.2.1.1<hh3cDLDPUnidirectionalPort>: DLDP detects a unidirectional link in port 17825792.
%Jan 18 17:36:18:799 2010 DeviceA IFNET/3/LINK_UPDOWN: GigabitEthernet2/0/1 link status is DOWN.
%Jan 18 17:36:18:799 2010 DeviceA DLDP/3/DLDP_UNIDIRECTION_AUTO: -Slot=2; DLDP detects a unidirectional link on port GigabitEthernet2/0/1. The transceiver has malfunction in the Tx direction or cross-connected links exist between the local device and its neighbor. The shutdown mode is AUTO. DLDP shuts down the port.
#Jan 18 17:36:20:189 2010 DeviceA DLDP/1/TrapOfUnidirectional: -Slot=2; Trap 1.3.6.1.4.1.25506.2.43.2.1.1<hh3cDLDPUnidirectionalPort> : DLDP detects a unidirectional link in port 17825793.
%Jan 18 17:36:20:189 2010 DeviceA IFNET/3/LINK_UPDOWN: GigabitEthernet2/0/2 link status is DOWN.
%Jan 18 17:36:20:190 2010 DeviceA DLDP/3/DLDP_UNIDIRECTION_AUTO: -Slot=2; DLDP detects a unidirectional link on port GigabitEthernet2/0/2. The transceiver has malfunction in the Tx direction or cross-connected links exist between the local device and its neighbor. The shutdown mode is AUTO. DLDP shuts down the port.
%Jan 15 16:54:56:040 2010 DeviceA DLDP/3/DLDP_UNIDIRECTION_AUTO_ENHANCE: -Slot=2; In enhanced DLDP mode, port GigabitEthernet2/0/1 cannot detect its aged-out neighbor. The transceiver has malfunction in the Tx direction or cross-connected links exist between the local device and its neighbor. The shutdown mode is AUTO. DLDP shuts down the port.
The output shows that both GigabitEthernet 2/0/1 and GigabitEthernet 2/0/2 are down. DLDP has detected a unidirectional link on both ports, and has automatically shut them down.
# Remove the unidirectional condition.
The ports shut down by DLDP automatically recover, and Device A displays the following log information:
<DeviceA>
%Jan 18 17:47:33:869 2010 DeviceA IFNET/3/LINK_UPDOWN: GigabitEthernet2/0/1 link status is UP.
%Jan 18 17:47:35:894 2010 DeviceA IFNET/3/LINK_UPDOWN: GigabitEthernet2/0/2 link status is UP.
Configuration files
· Device A:
#
dldp enable
dldp work-mode enhance
#
interface GigabitEthernet3/0/1
port link-mode bridge
speed 1000
duplex full
dldp enable
#
interface GigabitEthernet3/0/2
port link-mode bridge
speed 1000
duplex full
dldp enable
· Device B:
#
dldp enable
dldp work-mode enhance
#
interface GigabitEthernet3/0/1
port link-mode bridge
speed 1000
duplex full
dldp enable
#
interface GigabitEthernet3/0/2
port link-mode bridge
speed 1000
duplex full
dldp enable
Example: Manually shutting down unidirectional links
Network requirements
As shown in Figure 2, Device A and Device B are connected with two fiber pairs.
Configure DLDP to detect unidirectional links. When a unidirectional link is detected, the administrator must manually shut down the port.
Requirements analysis
In this example, the unidirectional link might be caused by cross-connected fiber, connectionless fiber, or broken fiber. To enable DLDP to successfully detect the unidirectional link, configure DLDP to operate in enhanced mode.
When DLDP detects a unidirectional link, you must manually shut down the faulty port. Set the port shutdown mode to manual (the default mode is auto).
Software version used
This configuration example was created and verified on S12500-CMW520-R1825P01.
Configuration restrictions and guidelines
When you configure DLDP to ask you to manually shut down unidirectional links, follow these restrictions and guidelines:
· DLDP is available only for Ethernet ports.
· To correctly configure DLDP, first enable DLDP globally, and then enable it on each port.
· For DLDP to operate correctly, configure the same forced speed and full duplex mode on both ends.
· DLDP can detect unidirectional links only after all links are physically connected. Before enabling DLDP, make sure optical fibers or copper twisted pairs are connected.
· For DLDP to work correctly, enable DLDP on both ends, and make sure the following settings are consistent:
¡ Interval for sending Advertisement packets.
¡ DLDP authentication mode.
¡ Password.
Configuration procedures
Configuring Device A
# Enable DLDP globally.
<DeviceA> system-view
[DeviceA] dldp enable
# Configure GigabitEthernet 2/0/1 to operate in full duplex mode, configure the port rate as 1000 Mbps, and enable DLDP on the port.
[DeviceA] interface gigabitethernet 2/0/1
[DeviceA-GigabitEthernet2/0/1] undo shutdown
[DeviceA-GigabitEthernet2/0/1] duplex full
[DeviceA-GigabitEthernet2/0/1] speed 1000
[DeviceA-GigabitEthernet2/0/1] dldp enable
[DeviceA-GigabitEthernet2/0/1] quit
# Configure GigabitEthernet 2/0/2 to operate in full duplex mode, configure the port rate as 1000 Mbps, and enable DLDP on the port.
[DeviceA] interface gigabitethernet 2/0/1
[DeviceA-GigabitEthernet2/0/1] undo shutdown
[DeviceA-GigabitEthernet2/0/1] duplex full
[DeviceA-GigabitEthernet2/0/1] speed 1000
[DeviceA-GigabitEthernet2/0/1] dldp enable
[DeviceA-GigabitEthernet2/0/1] quit
# Set the DLDP mode to enhanced.
[DeviceA] dldp work-mode enhance
# Set the port shutdown mode to manual.
[DeviceA] dldp unidirectional-shutdown manual
Configuring Device B
# Enable DLDP globally.
<DeviceB> system-view
[DeviceB] dldp enable
# Configure GigabitEthernet 2/0/1 to operate in full duplex mode, configure the port rate as 1000 Mbps, and enable DLDP on the port.
[DeviceB] interface gigabitethernet 2/0/1
[DeviceB-GigabitEthernet2/0/1] undo shutdown
[DeviceB-GigabitEthernet2/0/1] duplex full
[DeviceB-GigabitEthernet2/0/1] speed 1000
[DeviceB-GigabitEthernet2/0/1] dldp enable
[DeviceB-GigabitEthernet2/0/1] quit
# Configure GigabitEthernet 2/0/2 to operate in full duplex mode, configure the port rate as 1000 Mbps, and enable DLDP on the port.
[DeviceB] interface gigabitethernet 2/0/2
[DeviceB-GigabitEthernet2/0/2] undo shutdown
[DeviceB-GigabitEthernet2/0/2] duplex full
[DeviceB-GigabitEthernet2/0/2] speed 1000
[DeviceB-GigabitEthernet2/0/2] dldp enable
[DeviceB-GigabitEthernet2/0/2] quit
# Set the DLDP mode to enhanced.
[DeviceB] dldp work-mode enhance
# Set the port shutdown mode to manual.
[DeviceB] dldp unidirectional-shutdown manual
Verifying the configuration
After the configurations are complete, you can use the display dldp command to display the DLDP configuration information on ports.
# Display the DLDP configuration information on all the DLDP-enabled ports of Device A.
[DeviceA] display dldp
DLDP global status : enable
DLDP interval : 5s
DLDP work-mode : enhance
DLDP authentication-mode : none
DLDP unidirectional-shutdown : manual
DLDP delaydown-timer : 1s
The number of enabled ports is 2.
Interface GigabitEthernet2/0/1
DLDP port state : advertisement
DLDP link state : up
The neighbor number of the port is 1.
Neighbor mac address : 0023-8956-3600
Neighbor port index : 59
Neighbor state : two way
Neighbor aged time : 11
Interface GigabitEthernet2/0/2
DLDP port state : advertisement
DLDP link state : up
The neighbor number of the port is 1.
Neighbor mac address : 0023-8956-3600
Neighbor port index : 60
Neighbor state : two way
Neighbor aged time : 12
The output shows that both GigabitEthernet 2/0/1 and GigabitEthernet 2/0/2 are in Advertisement state, which means both links are bidirectional.
# Enable system information monitoring on Device A, and enable the display of log and trap information.
[DeviceA] quit
<DeviceA> terminal monitor
<DeviceA> terminal logging
<DeviceA> terminal trapping
The following log and trap information is displayed on Device A:
<DeviceA>
#Jan 18 18:10:38:481 2010 DeviceA DLDP/1/TrapOfUnidirectional: -Slot=2; Trap 1.3.6.1.4.1.25506.2.43.2.1.1<hh3cDLDPUnidirectionalPort> : DLDP detects a unidirectional link in port 17825792.
%Jan 18 18:10:38:481 2010 DeviceA DLDP/3/DLDP_UNIDIRECTION_MANUAL: -Slot=2; DLDP detects a unidirectional link on port GigabitEthernet2/0/1. The transceiver has malfunction in the Tx direction or cross-connected links exist between the local device and its neighbor. The shutdown mode is MANUAL. The port needs to be shut down by the user.
#Jan 18 18:10:38:618 2010 DeviceA DLDP/1/TrapOfUnidirectional: -Slot=2; 1.3.6.1.4.1.25506.2.43.2.1.1<hh3cDLDPUnidirectionalPort> : DLDP detects a unidirectional link in port 17825793.
%Jan 18 18:10:38:618 2010 DeviceA DLDP/3/DLDP_UNIDIRECTION_MANUAL: -Slot=2; DLDP detects a unidirectional link on port GigabitEthernet2/0/2. The transceiver has malfunction in the Tx direction or cross-connected links exist between the local device and its neighbor. The shutdown mode is MANUAL. The port needs to be shut down by the user.
The output shows that DLDP has detected a unidirectional link on both GigabitEthernet 2/0/1 and GigabitEthernet 2/0/2, and is asking you to shut down the faulty ports.
After you shut down GigabitEthernet 2/0/1 and GigabitEthernet 2/0/2, the following log information is displayed:
<DeviceA> system-view
[DeviceA] interface gigabitethernet 2/0/1
[DeviceA-GigabitEthernet2/0/1] shutdown
%Jan 18 18:16:12:044 2010 DeviceA IFNET/3/LINK_UPDOWN: GigabitEthernet2/0/1 link status is DOWN.
[DeviceA-GigabitEthernet2/0/1] quit
[DeviceA] interface gigabitethernet 2/0/2
[DeviceA-GigabitEthernet2/0/2] shutdown
%Jan 18 18:18:03:583 2010 DeviceA IFNET/3/LINK_UPDOWN: GigabitEthernet2/0/2 link status is DOWN.
The output shows that the link status of both GigabitEthernet 2/0/1 and GigabitEthernet 2/0/2 is down.
Remove the unidirectional link condition, and then bring up the ports shut down earlier.
# On Device A, bring up GigabitEthernet 2/0/1 and GigabitEthernet 2/0/2:
[DeviceA-GigabitEthernet2/0/2] undo shutdown
[DeviceA-GigabitEthernet2/0/2]
%Jan 18 18:22:11:698 2010 DeviceA IFNET/3/LINK_UPDOWN: GigabitEthernet2/0/2 link status is UP.
[DeviceA-GigabitEthernet2/0/2] quit
[DeviceA] interface gigabitethernet 2/0/1
[DeviceA-GigabitEthernet2/0/1] undo shutdown
[DeviceA-GigabitEthernet2/0/1]
%Jan 18 18:22:46:065 2010 DeviceA IFNET/3/LINK_UPDOWN: GigabitEthernet2/0/1 link status is UP.
Configuration files
· Device A:
#
dldp enable
dldp work-mode enhance
dldp unidirectional-shutdown manual
#
interface GigabitEthernet3/0/1
port link-mode bridge
speed 1000
duplex full
dldp enable
#
interface GigabitEthernet3/0/2
port link-mode bridge
speed 1000
duplex full
dldp enable
· Device B:
#
dldp enable
dldp work-mode enhance
dldp unidirectional-shutdown manual
#
interface GigabitEthernet3/0/1
port link-mode bridge
speed 1000
duplex full
dldp enable
#
interface GigabitEthernet3/0/2
port link-mode bridge
speed 1000
duplex full
dldp enable
Related documentation
· H3C S12500 Series Routing Switches High Availability Configuration Guide
· H3C S12500 Series Routing Switches High Availability Command Reference