ethtool hints
Is this a good idea? Turns out ๐ค…
๐คท prolly not… ?
Linux Ethtool Commands
Command Description
ethtool -s ethX speed 25000 autoneg off
Force the speed to 25G. If the link is up on one port, the driver does not allow the other port to be set to a different speed.
ethtool -i ethX
Output includes driver, firmware, and package version.
ethtool -k ethX
Show offload features.
ethtool -K ethX tso off
Turn off TSO.
ethtool -K ethX gro off lro off
Turn off GRO/LRO.
ethtool -g ethX
Show ring sizes.
ethtool -G ethX rx N
Set ring sizes.
ethtool -S ethX
Get statistics.
ethtool -l ethX
Show number of rings.
ethtool -L ethX rx 0 tx 0 combined M
Set number of rings.
ethtool -C ethX rx-frames N
Set interrupt coalescing. Other parameters supported are rx-usecs, rx-frames, rx-usecs-irq, rx-frames-irq, tx-usecs, tx-frames, tx-usecs- irq, tx-frames-irq.
ethtool -x ethX
Show RSS flow hash indirection table and RSS key.
ethtool -s ethX autoneg on speed 10000 duplex full
Enable Autoneg.
ethtool –show-eee ethX
Show EEE state.
ethtool –set-eee ethX eee off
Disable EEE.
ethtool –set-eee ethX eee on tx-lpi off
Enable EEE, but disable LPI.
ethtool -L ethX combined 1 rx 0 tx 0
Disable RSS. Set the combined channels to 1.
ethtool -K ethX ntuple off
Disable Accelerated RFS by disabling ntuple filters.
ethtool -K ethX ntuple on
Enable Accelerated RFS.
ethtool -t ethX
Performs various diagnostic self-tests.
ethtool -m ethX
Query/Decode module EEPROM information and optical diagnostics if available.
echo 32768 > /proc/sys/net/core/ rps_sock_flow_entries echo 2048 > /sys/class/net/ethX/queues/rx-X/ rps_flow_cnt
Enable RFS for ring X.
sysctl -w net.core.busy_read=50
This sets the time to read the device’s receive ring to 50 ฮผsecs. For socket applications waiting for data to arrive, using this method can decrease latency by 2 or 3 ฮผs typically at the expense of higher CPU utilization.
echo 4 > /sys/class/net/