Hey everyone 👋
Janith here. Today, let’s talk about Wake-On-LAN (WOL).
This post is for anyone who has ever had the idea of turning on their PC remotely. I recently set this up on my own machines, and while it worked perfectly on my Windows desktop, my old Ubuntu laptop taught me some important hardware lessons.
If you’re experimenting with homelabs or self-hosting, this is a really cool and useful thing to learn.
Why I Wanted Wake-on-LAN
My laptop isn’t in a place where I can access it quickly. Whenever I needed to turn on my server, I had to physically go to the laptop and press the power button.
And honestly… I’m a bit lazy 😄
That alone motivated me to look for a better solution.
My main goals were:
- Access my homelab remotely
- Avoid keeping machines powered on 24/7
- Learn how low-level networking features work
Wake-on-LAN sounded perfect for this.
What Is Wake-on-LAN (WOL)?
Wake-on-LAN allows you to power on a computer by sending a special magic packet over the network.
There is another feature called Wake on WLAN which is a newer technology and available on newer pcs', where it allows the user to send the magic packet without requiring an Ethernet cable.
A few important requirements:
- Wired Ethernet (Wi-Fi usually doesn’t work from shutdown).
- BIOS/UEFI support
- OS-level configuration
From my experience:
Desktops work very reliably
Older laptops often have limitations (Your Computer might not support WOL)
Enable Wake-on-LAN in BIOS / UEFI
Before touching the operating system, check the BIOS.
Steps:
Restart and enter BIOS (Del, F2, F10, or F12)
Look for options like:
- Wake on LAN
- Power On by LAN
- Resume by PCI-E
Enable the option and save
Important note:
My Dell Inspiron 3542 laptop had no WOL option at all, which is very common for consumer laptops.
Windows Setup (Worked Perfectly for Me)
Configure the Network Adapter
Go to:
Device Manager → Network adapters → Ethernet adapter → Properties
Power Management tab
- Allow this device to wake the computer
- Only allow a magic packet to wake the computer
Advanced tab
- Wake on Magic Packet → Enabled
- Wake on Pattern Match → Enabled
- Energy Efficient Ethernet → Disabled (if available)
Get the MAC Address
ipconfig /all
Look for the Physical Address of your Ethernet adapter.
Test It
Shut down the PC completely and send a WOL packet from your phone.
(you will have to find an app that does this. I use the app called Wake On Lan)
Result:
My Windows desktop woke up instantly every time.
Ubuntu / Linux Setup
I installed Ubuntu Server on an old laptop and configured WOL. Although the process wasn't successful, I will document the process i have followed.
The network card technically supported WOL, but the laptop hardware cut power during shutdown.
Install ethtool
sudo apt update
sudo apt install ethtool
Find your network interface:
ip link show
Mine was enp7s0.
Enable Wake-on-LAN
sudo ethtool -s enp7s0 wol g
Check support:
ethtool enp7s0
You should see something like:
Supports Wake-on: pumbg
Wake-on: g
Make It Persistent
Create a systemd service:
sudo nano /etc/systemd/system/wol.service
once the file opens:
[Unit]
Description=Enable Wake-on-LAN
[Service]
Type=oneshot
ExecStart=/usr/sbin/ethtool -s enp7s0 wol g
[Install]
WantedBy=multi-user.target
Enable it:
sudo systemctl daemon-reload
sudo systemctl enable --now wol.service
Result
- Works perfectly from suspend
- Does not work from full shutdown (Should work if your pc supports WOL)
- Ethernet LEDs turn off completely when powered down
Lesson learned:
Many older laptops remove power from the network card when shut down. Software can’t fix that.
You need to add your MAC address and your IP address into the app and keep the default settings.
- MAC address
- Broadcast IP (for example: 192.168.1.255)
- Port: 9 or 7
Once configured, waking the machine takes a single tap.
Waking Over the Internet
There are two main approaches:
Port Forwarding (Not Recommended)
- Forward UDP port 9
- Works, but exposes your network to the internet
VPN (Recommended)
- Set up WireGuard
- Connect your phone to the VPN
- Send the WOL packet as if you’re at home
This approach is safer and more reliable.
Troubleshooting Tips
Things I learned the hard way:
- Ethernet LEDs staying on after shutdown is a good sign
- Always test WOL locally first
- Laptops work better from suspend than shutdown
- Plug in the charger (some laptops disable WOL on battery)
- A smart plug can be a simple fallback solution
Final Thoughts
Wake-on-LAN is incredibly useful once it works.
This is just another step toward my larger automation goals. My end goal is to set up a Home Assistant system where I can control all my smart devices from a centralized place.
I hope you learned something new, and I’ll be back with more cool stuff soon.
Thanks for reading 🙌
Happy learning!
Top comments (0)