• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

The Geek Diary

CONCEPTS | BASICS | HOWTO

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • Linux Services
    • VCS
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
    • Data Guard
  • DevOps
    • Docker
    • Shell Scripting
  • Interview Questions
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

How to Permanently set the ethtool settings in CentOS/RHEL 6

By admin

Modifications made with the ethtool command are by default disappeared after a reboot. For permanent settings, the interface configuration file has to be edited. For each network device, there will be a file in the /etc/sysconfig/network-scripts/

For example, for device eth0 there will be /etc/sysconfig/network-scripts/ifcfg-eth0 containing the properties of the device. A line can be added to the file to automatically implement the settings allowed by the “ethtool -s” command. For example:

# vi /etc/sysconfig/network-scripts/ifcfg-eth0
ETHTOOL_OPTS="autoneg off duplex full speed 100"

Refer to “man ethtools” for options allowed with the “-s” switch.

# man ethtool

These are the only switch options that can be implemented this way because the “ifup” script is not coded to handle other options.

Restart the network service for the changes to take effect:

# service network restart

If this is not the primary interface in use and you have logged in with another IP that is not plumbed to this interface, you can also use “ifdown” and “ifup” commands to make the ethtool settings active.

# ifdown eth0
ifup eth0

These settings will be set permanently, so even after a reboot of the servers you should see these settings intact.

Filed Under: CentOS/RHEL, CentOS/RHEL 6, Linux

Some more articles you might also be interested in …

  1. Linux / UNIX : How to send mails with attachments using mailx command
  2. “Metadata File Does Not Match Checksum” Issue When Yum Installs or Updates Package
  3. Filesystems Are Not Getting Mounted in Order on CentOS/RHEL 7
  4. Failed to Download Metadata for Repo ‘repo_name’
  5. How to Trace Python Scripts using trace.py
  6. How to Re-generate initramfs and vmlinuz for Rescue Kernel with Current Kernel in CentOS/RHEL 7
  7. How to configure VNC Server on Oracle Linux 6
  8. How to Install Apache, MariaDB, and PHP (FAMP) stack on FreeBSD 11
  9. CentOS / RHEL 6 : How to add/remove additional IP addresses to a network interface
  10. Troubleshooting Common GUI / X-Window Issues on CentOS/RHEL

You May Also Like

Primary Sidebar

Recent Posts

  • What are different Oracle Database Vault Roles
  • Unable to export realm protected table using data pump
  • Beginners Guide to Oracle Database Vault
  • How to Disable IPv6 on Ubuntu 18.04 Bionic Beaver Linux
  • Archives
  • Contact Us
  • Copyright

© 2021 · The Geek Diary