Wake On Lan with UbuntuLinux
Wake-on-lan is incredibly useful for those scenarios where you have more than one machine on a network, but you don’t always want to have them running but they are needed sometimes.
To setup, make sure that the Motherboard and NIC support is there from your manufacturer. Sometimes it has to be enabled, such as making sure that it uses S3 for shutdown, and that PCI wake is supported.
Next you need to check support from the operating system, I am using Ubuntu 10.04, but this should work for other operating systems. Install ethtool, and then check against the ethernet adapter (eth0 in my example).
sudo apt-get install ethtool
sudo ethtool eth0
If support is enabled, but it is turned off you will see:
Supports Wake-on: g
So we turn it on:
sudo ethtool -s eth0 wol g
Now we need to make sure that its always enabled everytime we restart:
sudo vim wakeonlan
And in that file:
ethtool -s eth0 wol g
Now make sure that its put into the correct runlevels:
sudo chmod a+x wakeonlan
sudo update-rc.d -f wakeonlan defaults
And that is it. It should be supported that you can wake the machine from another computer/server using your favourite wakeup utility ( such as wakeonlan ).comments powered by Disqus