0

I have two machines, both running Ubuntu 18.04. My objective to to have WOL working on both machines.

On one machine (PC1) I have WOL working perfectly, however I cannot get WOL working on the other machine (PC2).

My Set up (on both PCs) is:

I have disabled Network Manager as follows:

sudo systemctl stop NetworkManager
sudo systemctl disable NetworkManager
sudo systemctl mask NetworkManager

I have enabled networkd as follows:

sudo systemctl unmask systemd-networkd.service
sudo systemctl enable systemd-networkd.service
sudo systemctl start systemd-networkd.service

I have modified the only file in directory /etc/netplan, namely /etc/netplan/01-network-manager-all.yaml so it looks like this (PC1):

network:
  version: 2
  renderer: networkd
  ethernets:
    eno1:
      addresses:
        - 192.168.1.113/24
      gateway4: 192.168.1.1
      wakeonlan: true
      nameservers:
        addresses: [103.86.96.100, 103.86.99.100]

PC2 is exactly the same except eno1 is enp1s0 and the IP address is different (of course).

Both machines boot up fine, the ethernet connection is OK, I can access internet OK from both machines.

If I type

sudo ethtool enp1s0

on PC2 I get this (extract):

Supports Wake-on: pumbg
Wake-on: d

on PC1 (eno1) I get (extract)

Supports Wake-on: pumbg
Wake-on: g

If I type (on PC2):

sudo ethtool -s enp1s0 wol g 

and then

sudo ethtool enp1s0

I get

Supports Wake-on: pumbg
Wake-on: g

If I then switch off PC2, WOL works as expected (but this, of course, is only 'one-time').

If I put the line sudo ethtool -s enp1s0 wol g in a startup script or a shutdown script that I have on PC2 (both run with sudo permissions) then WOL doesn't work.

The only difference I perceive between PC1 and PC2 is the motherboard; PC2 has a Gigabyte GA-H110M-S2H; PC1 has an ASUS SABERTOOTH X79)

I would be most grateful for any suggestions or insights anyone may have.

Thanks in advance.

2
  • Wouldn't wake on lan be more down to settings you have in BIOS rather than Ubuntu it self ? Which would explain the difference between two motherboards being a factor.
    – Oscar
    Feb 7, 2020 at 15:51
  • @Oskar-l thanks for you fast reply. Both the BIOS and Ubuntu System need to be configured. The wakeonlan: true in the yaml file should do the *Ubuntu System" part. I know the BIOS part is working because everything works as expected when I type *sudo ethtool -s enp1s0 wol g * on the CLI. Feb 7, 2020 at 16:00

1 Answer 1

0

Fixed.

This turns out to be a driver issue. The NIC on the Gigabyte GA-H110M-S2H is a Realtek 8168 device; Ubuntu was using a 8169 driver. To fix this I did the following:

sudo apt-get install r8168-dkms

The procedure took a little while because the new driver is built and installed to my Kernel. (The dkms ensures that that if any Kernel update happens then the new Kernel will be re-built automatically).

I had to reboot for WOL to work.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .