Setting the MTU of IPv4 packets sent over an interface
When a packet exceeds the MTU of IPv4 packets sent over an interface, the device processes the packet in one of the following ways:
If the packet disallows fragmentation, the device discards it.
If the packet allows fragmentation, the device fragments it and forwards the fragments.
Fragmentation and reassembling consume system resources, so set the MTU based on the network environment to avoid fragmentation.
To set the MTU of IPv4 packets sent over an interface:
Step | Command | Remarks |
---|---|---|
1. Enter system view. | system-view | N/A |
2. Enter interface view. | interface interface-type interface-number | N/A |
3. Set the MTU of IPv4 packets sent over the interface. | ip mtu mtu-size | By default, the MTU of IPv4 packets sent over the interface is not set. |