Wake-up / shutdown (linux)

How to configure power buton/ wake-on-lan and autoshutdown.

Power Buton

Within SystemD in /etc/systemd/logind.conf

HandlePowerKey=poweroff

sudo service systemd-logind restart

Wake-On-Lan

wakeonlan MAC Address

Get MAC Address with cat /sys/class/net/ens1f0/address or ip link show

Start / Shutdown discussion

Scheduled Shutdown

see Execute Task periodically

Run script after wakeup?

Written on April 27, 2019, Last update on October 22, 2023
linux-system power network systemd automation