Wake-on-LAN in the Homelab: Remote Power Management
Running servers 24/7 wastes electricity for machines that don't need to be on all the time. Wake-on-LAN (WoL) solves this: power off the machine when idle, send a "magic packet" to wake it remotely when needed. A NAS, gaming PC, or homelab server can be asleep and ready in under 30 seconds when you actually need it.
Photo by Nick Fewings on Unsplash
What Wake-on-LAN Is
WoL is a network standard where a machine listens for a specific Ethernet packet ("magic packet") even while powered off — as long as it has standby power (plugged in). The magic packet contains the target machine's MAC address repeated six times, preceded by six bytes of 0xFF.
Modern NICs support WoL, but it requires:
- BIOS/UEFI WoL enabled
- Operating system WoL configured
- Network infrastructure that can deliver the magic packet
Step 1: Enable in BIOS
Enter BIOS during POST (typically Delete or F2). Look under:
- Power Management → Wake-on-LAN
- Advanced → Power Options → Network Wake-Up
- Some boards label it "ErP Ready" or "Deep Power Off" — disable ErP to enable WoL
Different motherboard vendors use different menu names. The setting enables "standby power" to the NIC so it can receive packets while the machine is off.
Note: This doesn't work if the machine is disconnected from power or in a state with no standby power (some power strips cut all power).
Step 2: Enable in the Operating System
Linux (most distros)
Check WoL status with ethtool:
sudo apt install ethtool # if not installed
sudo ethtool eno1 | grep Wake-on
Output:
Supports Wake-on: pumbg
Wake-on: d ← "d" means disabled
Enable WoL:
sudo ethtool -s eno1 wol g # "g" = magic packet
This resets on reboot. Make it persistent via systemd:
# /etc/systemd/system/wol.service
[Unit]
Description=Enable Wake-on-LAN
After=network.target
[Service]
Type=oneshot
ExecStart=/sbin/ethtool -s eno1 wol g
RemainAfterExit=yes
[Install]
WantedBy=multi-user.target
sudo systemctl enable wol.service
sudo systemctl start wol.service
Or use NetworkManager (if using NM):
nmcli connection modify "Your Connection" 802-3-ethernet.wake-on-lan magic
Windows
- Device Manager → Network Adapters → Your NIC → Properties
- Power Management tab → ✓ "Allow this device to wake the computer"
- Advanced tab → "Wake on Magic Packet" → Enable
Also check: Power Options → Choose what the power buttons do → Turn on fast startup: Disable this. Fast startup (hybrid sleep) prevents WoL from working reliably.
Proxmox Host
On Proxmox (Debian-based):
# In /etc/network/interfaces, add post-up to your interface
post-up /usr/sbin/ethtool -s eno1 wol g
Or use the systemd service method above.
Like what you're reading? Subscribe to HomeLab Starter — free weekly guides in your inbox.
Step 3: Find the Machine's MAC Address
You need the MAC address to send the magic packet:
# Linux
ip link show eno1
# Look for: link/ether aa:bb:cc:dd:ee:ff
# Or from another machine using ARP (after initial connection)
arp -n | grep 192.168.1.x
Store the MAC address somewhere accessible (your phone, password manager, router config).
Sending the Magic Packet
From Linux/Mac (command line)
# Install wakeonlan
sudo apt install wakeonlan # Debian/Ubuntu
brew install wakeonlan # macOS
# Wake a machine
wakeonlan AA:BB:CC:DD:EE:FF
# Or specify broadcast address (useful if on different subnet)
wakeonlan -i 192.168.1.255 AA:BB:CC:DD:EE:FF
From Windows
# PowerShell one-liner
$mac = "AA:BB:CC:DD:EE:FF"
$bytes = [byte[]]((, 0xFF) * 6 + ($mac.Split(':') | foreach { [Convert]::ToByte($_, 16) }) * 16)
$udp = New-Object System.Net.Sockets.UdpClient
$udp.Connect("255.255.255.255", 9)
$udp.Send($bytes, $bytes.Length) | Out-Null
Or use GUI tools like "NirSoft WakeMeOnLan" (Windows) or WireShark.
From a Homelab Script or Automation
If you have a home server that's always on, put a simple WoL script on it:
#!/bin/bash
# wake-server.sh
wakeonlan AA:BB:CC:DD:EE:FF
echo "Magic packet sent. Waiting for server to come up..."
for i in {1..30}; do
ping -c 1 -W 1 192.168.1.50 > /dev/null 2>&1 && echo "Server is up!" && exit 0
sleep 2
done
echo "Server did not respond in 60 seconds"
Homelab Use Cases
NAS Power Management
Run your NAS only when needed. At 80W continuous, a NAS uses ~700 kWh/year. With WoL, power it on before a backup job runs, then power it off after. A scheduled script on a Pi Zero:
# 2am: wake NAS
0 2 * * * wakeonlan AA:BB:CC:DD:EE:FF
# 4am: shut down NAS (after backups complete)
0 4 * * * ssh [email protected] "sudo shutdown -h now"
Gaming PC Access
Wake your gaming PC remotely via Parsec or Moonlight for remote gaming, without leaving it on 24/7.
Proxmox Development Server
Keep your Proxmox server powered off most of the time. Wake it when you want to work on VMs, then shut down when done.
WoL Over the Internet
WoL magic packets are broadcast, which routers don't route across subnets. To wake a machine from outside your home:
Option 1: VPN (recommended)
With WireGuard or Tailscale, you're on your home network. From within the VPN:
wakeonlan AA:BB:CC:DD:EE:FF
Some routers also support directed broadcasts to your subnet (192.168.1.255), which works without VPN.
Option 2: Always-on relay
Keep a low-power device (Raspberry Pi, VPS, or always-on router) that can receive a command and forward the magic packet:
# On the Pi (always on):
# Simple HTTP endpoint using socat or a tiny web server
# POST /wake → run wakeonlan
Option 3: Router WoL support
Some routers (Asus with Merlin firmware, OpenWrt) have built-in WoL capability in their web interface. You can trigger it from anywhere.
Troubleshooting
Machine doesn't wake:
- Verify BIOS setting is saved (re-enter BIOS and confirm)
- Verify OS config is persistent across reboots (test by rebooting and rechecking
ethtool) - Ensure the NIC is receiving standby power (machine must stay plugged into power)
- Disable fast startup on Windows
- Some newer Intel NICs have a separate "Deep Sleep" setting that must be disabled
Machine wakes but can't connect:
- WoL works before the OS fully boots — wait 30-60 seconds after sending the packet
- Check if services are starting correctly on boot
WoL worked once, stopped working:
- OS updates sometimes reset the ethtool setting — check the systemd service is active
Power Consumption Context
| State | Typical draw |
|---|---|
| Full operation | 50-150W |
| Sleep/suspend | 1-5W |
| Off (with WoL standby) | 1-3W |
| Off (no standby) | 0W |
WoL requires the machine to be "soft off" (S5 ACPI state) — plugged in, BIOS powered, but OS off. This uses 1-3W. If you want truly zero draw, you need smart plugs and a different power-on mechanism (though smart plugs with WoL are a popular combo for NAS management).
