How do I add ethtool settings to a network device permanently?

ethtool can be used to set options for many types of Ethernet devices. The /etc/sysconfig/network-scripts/ifcfg-ethX files can have the ethtool settings added to them so that the settings are saved and used every time the device is activated.

For example, the command:
ethtool speed 100 duplex full autoneg off

sets the eth0 device to 100Mbs, full duplex, with auto negotiation off. To have the initialization scripts set this every time the eth0 device is activated, add a line to the /etc/sysconfig/network-scripts/ifcfg-eth0 file:

ETHTOOL_OPTS="speed 100 duplex full autoneg off"

 

 

source: https://sysadmincorner.wordpress.com/category/linux/networking/

Attachments
There are no attachments for this article.
Related Articles RSS Feed
CentOS / RHEL : Configure yum automatic updates with yum-cron service
Viewed 3713 times since Fri, Oct 26, 2018
stunnel: Authentication
Viewed 9347 times since Fri, Sep 28, 2018
red hat 7 tmpfiles service
Viewed 2044 times since Thu, Oct 11, 2018
How to use yum-cron to automatically update RHEL/CentOS Linux
Viewed 2881 times since Wed, Oct 17, 2018
10 Linux nslookup Command Examples for DNS Lookup
Viewed 10439 times since Sun, Sep 30, 2018
LVM: Extend SWAP size by growing existing Logical Volume
Viewed 2682 times since Sat, Jun 2, 2018
high swap space utilization in LINUX
Viewed 6760 times since Fri, Jul 13, 2018
How to Migrate from RHEL 8 to CentOS 8
Viewed 3322 times since Fri, May 15, 2020
How to Synchronize Directories Using Lsyncd in Linux
Viewed 14267 times since Wed, Oct 31, 2018
How setting the TZ environment variable avoids thousands of system calls
Viewed 10419 times since Mon, May 21, 2018