How to wake on lan with Fedora?

I’ve been trying to wake-on-lan my Fedora desktop, and haven’t succeeded, what am I doing wrong?

Setup

I have a mini PC, and a desktop, both Fedora 44. From my mini PC, I tried:

$ sudo ether-wake -i enp2s0 <desktop-ethernet-mac-address>

The mini PC and the desktop are connected via network switch in an isolated subnet.

I don’t get any errors, but neither does my desktop wakeup.

Is the machine configured to WoL in the BIOS?

Yes, unless I misunderstood the BIOS menus.

# ethtool <interface> | grep -i wake
Supports Wake-on: pumbg
	Wake-on: g          <- wol enabled by magic packet> 

arm wol on interface

# ethtool -s <interface> wol g 

see man ethtool for details

Obvious questions, which I presume you’ve already worked thorugh:

  • Is that the correct interface?
  • Does the target machine’s NIC actually support WoL?
  • Does it wake from Suspend and fails to awake from a full shutdown?
  • Does a tcpdump running on the target actually see the WoL packet arrive?

It was on d, after running the second command it is g now. I didn’t know this was necessary.

I’ll try again and report back.

Still very helpful to be reminded of them!

There is only one on the target, and the 2nd port on the source is not connected, but I’ve double checked (using ip addr), the device names and mac address is correct

Yes

$ sudo ethtool enp7s0 | grep -i wake
	Supports Wake-on: pumbg
	Wake-on: g

I don’t suspend my desktop, on or shutdown. I was trying to wake it up when it was completely shutdown.

This was not obvious to me, now that you mention it, seems obvious to check! However I don’t know which tool I can use to check this? I’m a networking n00b :face_with_tongue:

I asked about the does it WoL from suspend versus WoL from shutdown to see if the system/BIOS actually does WoL at all.

sudo tcpdump -i enpXsY -X

Then send the packet.

A WoL magic packet contains FF FF FF FF FF FF followed by the destination MAC repeated 16 (I think!) times.

Thanks! That worked :slight_smile:

Okay, I’ll try this out (for my learning). Thanks again :slight_smile: