Wake-up / shutdown ⏼

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

pi 5 now has bin/wake_up tronaut script

see also

# CLI

wakeonlan MAC Address

Get MAC Address with

  • ip link show
  • or cat /sys/class/net/ens1f0/address or

# Run script after wakeup ⮺

# Scheduling ⏰

see also Execute Task periodically

# Shutdown

$ sudo shutdown -h 23:30

# Sleep ⮺

$ echo "systemctl suspend" | at 23:30
Written on April 27, 2019, Last update on August 14, 2026
linux-system power watchdog network systemd automation