Permanently enable wake-on-lan with nmcli

First, check that the interface supports WoL:

sudo ethtool enp4s0 |grep Wake
    Supports Wake-on: g
    Wake-on: d

Supports Wake-on: g is required for WoL to work. You can change the setting with ethtool or NetworkManager. When you use ethtool, the change does not survive a reboot.

sudo ethtool -s enp4s0 wol g

By using Network Manager nmcli commands, the change persists reboots.

sudo nmcli conn mod enp4s0 802-3-ethernet.wake-on-lan magic
sudo nmcli conn up enp4s0

After applying the setting you can check again with ethtool

sudo ethtool enp4s0 | grep -i wake

Theme by Danetsoft and Danang Probo Sayekti inspired by Maksimer