Fragmentation and MTU
 


MTU/maximum transmission unit is the maximum length for an IP packet.

MTU can vary based on configurations and interfaces.  By default, a computer calculates an interface’s MTU based on the maximum size of the data portion of the data-link frame.  Default MTU on Ethernet is 1500.

Routers cannot forward a packet out an interface if the packet is longer than the MTU.  If a router’s interface MTU is smaller than a packet that must be forwarded, the router fragments the packets into smaller packets.  This process is called fragmentation.

The IP header contains fields for reassembling the fragments into the original packet.  The IP header includes an ID value that is the same in each fragmented packet, as well as an offset value that defines which part of the original packet is held in each fragment.  Fragmented packets arriving out of order can be identified as part of the same original packet and can be assembled in the correct order using the offset field in each fragment.

The mtu interface subcommand sets the MTU for all Layer 3 protocols, unless a need exists to vary the setting per Layer 3 protocol, this command is preferred.  If a different setting is desired for IP, the ip mtu interface subcommand sets the value used for IP.  If both are configured on an interface, the IP MTU setting takes precedence.  If the mtu command is configured after ip mtu is configured, the ip mtu value is reset to the same value as that of the mtu command.