(Optional) Configuring MPLS MTU
Context
The size of the maximum transmission unit (MTU) determines the maximum number of bytes that can be transmitted by the sender at a time. If the MTU exceeds the maximum number of bytes supported by the receiver or a transit device, packets are fragmented or even discarded, which increases the network transmission load. In this manner, devices have to calculate the MTU before the communication to ensure that sent packets reach the receiver successfully.
LDP MTU = Min {All MTUs advertised by all downstream devices, MTU of the local outbound interface}
If an interface MTU but not an MPLS MTU is configured on an interface, the interface MTU is used.
If both an MPLS MTU and an interface MTU are configured on an interface, the smaller value between the MPLS MTU and the interface MTU is used.
Procedure
- Run system-view
The system view is displayed.
- Run mpls ldp
The MPLS LDP view is displayed.
- Run the following commands as required.
Run mtu-signalling disable
The LSR is disabled from sending Label Mapping messages carrying MTU TLVs.
By default, the switch enables Label Mapping messages from carrying an MTU TLV.
Run mtu-signalling apply-tlv
The LSR is configured to send Label Mapping messages carrying MTU TLVs that comply with RFC 3988.
By default, the switch sends Label Mapping messages carrying Huawei proprietary MTU TLV.
- Run quit
The system view is displayed.
- Run interface interface-type interface-number
The view of an MPLS-enabled interface is displayed.
- On an Ethernet interface, run undo portswitch
The interface is switched to Layer 3 mode.
By default, an Ethernet interface works in Layer 2 mode.
The mode switching function takes effect when the interface only has attribute configurations (for example, shutdown and description configurations). Alternatively, if configuration information supported by both Layer 2 and Layer 3 interfaces exists (for example, mode lacp and lacp system-id configurations), no configuration that is not supported after the working mode of the interface is switched can exist. If unsupported configurations exist on the interface, delete the configurations first and then run the undo portswitch command.
If many Ethernet interfaces need to be switched to Layer 3 mode, run the undo portswitch batch interface-type { interface-number1 [ to interface-number2 ] } &<1-10> command in the system view to switch these interfaces to Layer 3 mode in batches.
- Run mpls mtu mtu
An MPLS MTU is configured on the interface.
By default, the MTU of MPLS packets is equal to the interface MTU.
- Run commit
The configuration is committed.