HowTo : Change Speed and Duplex of Ethernet card in Linux
To change Speed and Duplex of an ethernet card, we can use ethtool - a Linux utility for Displaying or Changing ethernet card settings.
1. Install ethtool
You can install ethtool by typing one of the following commands, depending upon your Linux distribution.
Install ethtool in Fedora, CentOS, RHEL etc. :
Install ethtool in Ubuntu, Debian etc. :
2. Get the Speed, Duplex and other information for the interface eth0
To get speed, duplex and other information for the network interface eth0, type the following command as root.
Sample output :
Settings for eth0: Supported ports: [ MII ] Supported link modes: 10baseT/Half 10baseT/Full 100baseT/Half 100baseT/Full 1000baseT/Half 1000baseT/Full Supports auto-negotiation: Yes Advertised link modes: 10baseT/Half 10baseT/Full 100baseT/Half 100baseT/Full 1000baseT/Half 1000baseT/Full Advertised auto-negotiation: Yes Speed: 100Mb/s Duplex: Half Port: Twisted Pair PHYAD: 1 Transceiver: internal Auto-negotiation: on Supports Wake-on: g Wake-on: d Current message level: 0x000000ff (255) Link detected: yes
3. Change the Speed and Duplex settings
The next command enables Auto-Negotiate feature :
The next command disables Auto-Negotiation, enables Half Duplex and sets up Speed to 10 Mb/s :
The next command disables Auto-Negotiation, enables Full Duplex and sets up Speed to 100 Mb/s :
4. Change the Speed and Duplex settings Permanently on CentOS/RHEL
To make settings permanent, you need to edit
Append the line as follows to disable Auto-Negotiation, enable Full Duplex and set up Speed to 100 Mb/s :
ETHTOOL_OPTS="speed 100 duplex full autoneg off"
Restart the interface to apply changes :