The mpls switch-l2vc encapsulation switchover command forcibly switches traffic from the primary PW to the secondary PW.
The undo mpls switch-l2vc encapsulation switchover command forcibly switches traffic from the secondary PW back to the primary PW.
By default, the mpls switch-l2vc switchover command is not configured.
Parameter | Description | Value |
---|---|---|
ip-address |
Specifies the IP address of U-PE. The value is the LSR ID of the peer device. |
The value is in dotted decimal notation. |
vc-id |
Specifies the ID of a Layer 2 VC. |
The value is a decimal integer ranging from 1 to 4294967295. |
encapsulation |
Specifies the type of PW encapsulation mode. |
- |
ethernet |
This encapsulation type is used when Ethernet packets do not carry VLAN information. |
- |
ip-interworking |
Enables heterogeneous media IP interworking between Huawei devices. |
- |
ip-layer2 |
Enables heterogeneous media IP interworking between a Huawei device and a non-Huawei device. |
- |
vlan |
This encapsulation type is used when Ethernet packets carry VLAN information. |
- |
Usage Scenario
On a large network, if two PEs cannot establish a signaling connection because they are in different ASs, you can configure PW switching on SPEs to connect the two PEs using an MS-PW.
If an SPE is configured with the primary and secondary PWs working in master/slave PW redundancy mode, traffic is transmitted over the primary PW in normal situations. If you want the traffic to be transmitted over the secondary PW due to reasons such as device upgrade or service re-deployment, you can use this command to forcibly switch traffic from the primary PW to the secondary PW. After the device is upgraded or services are re-deployed, you can run the undo mpls switch-l2vc switchover command to forcibly switch traffic from the secondary PW to the primary PW. If the primary PW is normal, traffic will be switched back to the primary PW after you run the undo mpls switch-l2vc switchover command.Prerequisites
MPLS and L2VPN have been enabled.
The primary and secondary PWs have been configured on the SPE using the mpls switch-l2vc command.Configuration Impact
PW signaling is not negotiated for a dynamic MS-PW on the SPE. Instead, PW information on both PEs is transparently transmitted on the SPE.
Exercise caution when using the undo mpls switch-l2vc all command because it will delete all the MS-PW on the devices. A PW switchover will be performed after you run the mpls switch-l2vc switchover or undo mpls switch-l2vc switchover command. If the PW to be switched to is Down or unavailable, the switchover fails.Follow-up Procedure
Run the display mpls switch-l2vc command to check whether the VC status is Up.
Precautions
The combination of the Peer IP, PW ID and PW type must be unique on a node. The PW IDs at the two ends of an MS-PW can be the same.
The VCCV feature is enabled by default and does not need to be configured. If the control word function is enabled, VCCV in control word mode is supported by default.<HUAWEI> system-view [~HUAWEI] mpls [*HUAWEI-mpls] quit [*HUAWEI] mpls l2vpn [*HUAWEI-l2vpn] quit [*HUAWEI] mpls switch-l2vc 1.1.1.1 1 between 2.2.2.2 2 backup 3.3.3.3 3 encapsulation vlan [*HUAWEI] mpls switch-l2vc 1.1.1.1 1 encapsulation vlan switchover