ethtool tso offloading
March 07, 2025
If you are experiencing slow network performance on a Linux server, it might be due to offloading features of the network card. Offloading is a technique used by network cards to offload the processing of network traffic from the CPU to the network card. This can improve performance by reducing the load on the CPU, but it can also cause problems if the network card is not properly configured.
To check the current offloading settings of a network card, you can use:
ethool -k eth0
To disable offloading features, you can use:
ethtool -K eth1 tso off gso off gro off
To enable them again, you can use:
ethtool -K eth1 tso on gso on gro on
For example, this is the output of iperf3
with offloading enabled:
-----------------------------------------------------------
[ ID] Interval Transfer Bitrate
[ 5] 0.00-1.00 sec 83.4 MBytes 700 Mbits/sec
[ 5] 1.00-2.00 sec 82.5 MBytes 692 Mbits/sec
[ 5] 2.00-3.00 sec 82.5 MBytes 692 Mbits/sec
[ 5] 3.00-4.00 sec 82.5 MBytes 692 Mbits/sec
[ 5] 4.00-5.00 sec 82.5 MBytes 692 Mbits/sec
[ 5] 5.00-6.00 sec 82.6 MBytes 693 Mbits/sec
[ 5] 6.00-7.00 sec 82.5 MBytes 692 Mbits/sec
[ 5] 7.00-8.00 sec 82.5 MBytes 692 Mbits/sec
[ 5] 8.00-9.00 sec 82.5 MBytes 692 Mbits/sec
[ 5] 9.00-10.00 sec 82.4 MBytes 691 Mbits/sec
[ 5] 10.00-10.00 sec 191 KBytes 691 Mbits/sec
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bitrate
[ 5] 0.00-10.00 sec 826 MBytes 693 Mbits/sec receiver
-----------------------------------------------------------
Server listening on 5201 (test #3)
And after disabling offloading:
[ ID] Interval Transfer Bitrate Retr Cwnd
[ 5] 0.00-1.00 sec 113 MBytes 948 Mbits/sec 0 379 KBytes
[ 5] 1.00-2.00 sec 113 MBytes 945 Mbits/sec 0 379 KBytes
[ 5] 2.00-3.00 sec 112 MBytes 942 Mbits/sec 0 397 KBytes
[ 5] 3.00-4.00 sec 112 MBytes 942 Mbits/sec 0 414 KBytes
[ 5] 4.00-5.00 sec 112 MBytes 939 Mbits/sec 0 414 KBytes
[ 5] 5.00-6.00 sec 112 MBytes 941 Mbits/sec 0 414 KBytes
[ 5] 6.00-7.00 sec 112 MBytes 943 Mbits/sec 0 414 KBytes
[ 5] 7.00-8.00 sec 112 MBytes 941 Mbits/sec 0 414 KBytes
[ 5] 8.00-9.00 sec 112 MBytes 942 Mbits/sec 0 414 KBytes
[ 5] 9.00-10.00 sec 112 MBytes 939 Mbits/sec 0 414 KBytes
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval Transfer Bitrate Retr
[ 5] 0.00-10.00 sec 1.10 GBytes 942 Mbits/sec 0 sender
[ 5] 0.00-10.00 sec 1.10 GBytes 941 Mbits/sec receiver
if you disable offloading you may notice more CPU usage, but the network performance should be better.