Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Make ethtool settings to your NIC persistent
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
Penulci
Tux's lil' helper
Tux's lil' helper


Joined: 12 Jun 2002
Posts: 119
Location: Vienna, Austria

PostPosted: Mon Aug 15, 2005 12:52 am    Post subject: Make ethtool settings to your NIC persistent Reply with quote

This "HOWTO" works for NIC drivers compiled into the kernel or compiled as modules.
Since i wanted to run WOL in my homenetwork I came to the problem that i had WOL enabled in BIOS (for my Onboard NIC) and also with
Code:
ethtool -s eth0 wol pumbg
on my NIC but everything was lost after the next reboot or powerdown.
Setting parameters for your NIC with ethtool should be no problem and is often discussed and explained in the forums.

To make your settings persistent (use them after a reboot or powerdown) you have to modify the init scripts, so be careful and follow these few steps:
    1) Backup your /etc/init.d/net.eth0 file (important!!!):
    Code:
    cp /etc/init.d/net.eth0 /etc/init.d/orig.net.eth0
    2) Edit your file /etc/init.d/net.eth0:
    Code:
    nano -w /etc/init.d/net.eth0
    Look for a line at the end of the file saying
    Code:
    local unset_functions=true
    This is the line shutting down your NIC to the factory defaults.
    3) Change the line to:
    Code:
    local unset_functions=false
    and save your modified file again as /etc/init.d/net.eth0
This is all you have to do to make the changes you make with ethtool to your NIC persistent, so you won't lose them after a reboot or shutdown.
In case you made a mistake you still have the Backup of your Original File.
Back to top
View user's profile Send private message
KaZeR
Apprentice
Apprentice


Joined: 04 Feb 2004
Posts: 291
Location: Au fond, à droite.

PostPosted: Tue Jul 25, 2006 4:21 pm    Post subject: Reply with quote

This is nice, but it has one default IMO : this config thing should be written in the network card setup file (net.eth0) rather, don't you think? Of course, this involves modifying two files, the config file and the init.d script but it would be 'cleaner', don't you think?
_________________
Foo.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum