Operating System - Linux
1828227 Members
2729 Online
109975 Solutions
New Discussion

Making ethtool changes permanent...

 
SOLVED
Go to solution
Lee Harris_5
Valued Contributor

Making ethtool changes permanent...

When changing LAN interface settings using ethtool for example like when manually setting a NIC to run at 100Mbps/Full Duplex, are these changes persistent across reboots, or will the card go back to the default of using AutoNeg after the server is rebooted?

If this is the case, how can I go about making these type of configuration changes permananet?
4 REPLIES 4
Vipulinux
Respected Contributor

Re: Making ethtool changes permanent...

Hi

You can either write the eth-tool config lines to /etc/rc.local

or
there are other option like editing the modules.conf file and ifeth0-up file as well.

Cheers
Sergejs Svitnevs
Honored Contributor

Re: Making ethtool changes permanent...

for Redhat you can put "ethtool -s eth0 speed 100 duplex full" into the "/etc/rc.local" file.

for Debian add next string into the "/etc/network/interfaces" file:
"post-up ethtool -s eth0 speed 100 duplex full".

This will set the NIC at eth0 to 100 full duplex when you boot up the server.

Regards,
Sergejs

Vitaly Karasik_1
Honored Contributor
Solution

Re: Making ethtool changes permanent...

In RH Linux you can just add

ETHTOOL_OPTS="speed 100 duplex full autoneg off"

into

/etc/sysconfig/network-scripts/ifcfg-eth[0,1]

But if you know what is NIC module params for setting duplex/speed, /etc/modules.conf is the best place for tuning!
Lee Harris_5
Valued Contributor

Re: Making ethtool changes permanent...

Thanks, putting the options into /etc/sysconfig/network-scripts/ifcfg-ethX worked perfectly!