Cookie

How to enable Jumbo Frames in Linux

Published by TheJoe on

Estimated reading time: 2 minutes

Caution


This article was published more than a year ago, there may have been developments.
Please take this into account.

The goal today is to reduce the stress on the LAN and free up some of the computational resources of the router. There will be no substantial differences in speed or not using Jumbo Frames, but this way we can reduce the time required for file transfer.

The Jumbo Frames are larger than normal network packet. The standard size of a package is 1.500 byte. The Jumbo Frames can instead increase the size of the packages up to 9.000.

I would like to warn users that the Jumbo Frame, although it supported by most devices on the market, I am still not a standard. It is also important to know that you will need to configure the network so that all the devices support Jumbo Frame. Having said this,, even if a device does not support them is not the end of the world. This means that device “break” the incoming packet from 9.000 bytes into multiple packets from 1.500. They are as though configure the router and any network switches.

freenas network settings
The configuration screen of FreeNAS network settings

Many routers let you change the MTU size (Maximum Transmission Unit). It is usually found in the network settings, but each manufacturer decides where to place it arbitrarily. Once you found it should be remembered that the maximum limit is 9.000 byte.

We check the size of the MTU

Now that the LAN supports Jumbo Frames, Also check if your computer is enabled. Probably you will be set 1.500 byte standard, but assicuriamocene.

We will investigate every aspect with the command ip, then we will use it to control the MTU size allowed by the network interface:

$ ip link list

And this is the output:

1:   lo: mtu 16436 qdisc noqueue
     link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2:   wlp5s0: mtu 1500 qdisc pfifo_fast qlen 1000
     link/ether 00:0f:ea:91:04:07 brd ff:ff:ff:ff:ff:ff

From the output we understand to be connected via Wi-Fi network, whose packets are “broken” every 1.500 byte.

Look here:  Change the password of a chrooted user

Temporarily set a new dimension

Set up a new dimension for each package is very simple with ip. We just have to tell the interface that we want to change, and the size to which we want to set them.

# ip link set wlp5s0 mtu 9000

You can set all interfaces on the computer if the hardware supports it:

# ip link set enp2s0 mtu 9000

Making changes permanent

The easiest thing is to create a script that starts at startup and set independently the MTU for all necessary interfaces.

#! /bin/bash

ip link set enp2s0 mtu 9000;
ip link set wlp5s0 mtu 9000;

We await that Jumbo Frames become standard.


TheJoe

I keep this blog as a hobby by 2009. I am passionate about graphic, technology, software Open Source. Among my articles will be easy to find music, and some personal thoughts, but I prefer the direct line of the blog mainly to technology. For more information contact me.

0 Comments

Leave a Reply

Avatar placeholder

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.