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
Get UUID of Hard Disks [Update]
Viewed 2121 times since Tue, Jul 17, 2018
Create a Linux Swap File
Viewed 2927 times since Fri, Jun 8, 2018
Using renice and taskset to manage process priority and CPU affinity with Linux OEL 6.4
Viewed 3515 times since Mon, Feb 17, 2020
RHEL: Extending the maximum inode count on a ext2/ext3/ext4 filesystem
Viewed 3072 times since Sun, May 27, 2018
10 nmap Commands Every Sysadmin Should Know
Viewed 9825 times since Wed, May 22, 2019
awk printf
Viewed 14924 times since Wed, Aug 19, 2020
Expand or grow a file system on a Linux VMWare VM without downtime
Viewed 11568 times since Fri, Jul 27, 2018
Monitoring bezpieczeństwa Linux: integracja auditd + OSSEC cz. I
Viewed 2364 times since Fri, Apr 5, 2019
Linux Network (TCP) Performance Tuning with Sysctl
Viewed 11425 times since Fri, Aug 3, 2018
Telnet – Send GET/HEAD HTTP Request
Viewed 3165 times since Mon, Feb 18, 2019