I have a number of systems I use at home, they run a combination of RHEL and Fedora and are a variety of architectures (well x86 and ARM). Travelling a lot for $dayjob I don’t always want them on needlessly chewing power but on the flip side if I’m away for two weeks and I’d like to remotely use one and it’s off it’s a little tough to power it up if you’re 12 hours travel away!
So the obvious solution to this problem to get the best of both worlds is to use Wake On LAN (WOL) for supported hardware which means I can leave devices off or suspended and then just bring them up to full power when I actually want to use them from where ever I happen to be at the time, whether it be on the couch across the room or the other side of the world.
There’s a few places where you need to configure the device you wish to wake up. If you want to wake from power off you need to configure the BIOS/Firmware to have WOL enabled, this differs from device to device so this bit is an exercise for the reader. The quickest way to determine if your hardware supports WOL and its enabled in the BIOS/Firmware is to check to see if when the device is turned off and cabled up to a switch is if there’s a link light on the NIC is still lit.
Once you’ve got the HW and BIOS/Firmware sorted the next bit is pretty straight forward. First enable WOL on boot for the NIC in /etc/sysconfig/network-scripts/ifcfg-
# ethtool -s
to enable it now. Finally record the ether address from the output from the “ip link” command so you know what MAC address you need to use to wake it up.
On your gateway make sure you have the appropriate tool to initiate the remote wakeup. On Fedora and RHEL this is ether-wake and it’s in the net-tools package. It’s then as simple as running
# ether-wake -i local-interface mac-address
6 thoughts on “Simple WOL with RHEL and Fedora”
Jednostavan WOL sa #RHEL i #Fedora http://t.co/yDBhOvfKpY
RT @FedoraSrbija: Jednostavan WOL sa #RHEL i #Fedora http://t.co/yDBhOvfKpY
Peter Robinson: Simple WOL with RHEL and Fedora http://t.co/5QF7TXZZdv
Peter Robinson: Simple WOL with RHEL and Fedora http://t.co/CwhZr0kvfY
I use WOL too at home, but how do you turn on the HW from the internet, behind a NAT? http://t.co/eZxoMTjdbM
@michalzuber You can’t, WOL only works on the same L2 network, I have a Linux based firewall that I can ssh into and I run the commands from that device which is always on
Comments are closed.