archlinux

Systemd Suspend Hook to Fix WiFi Arch Linux

Jun 28, 2017
archlinux, linux, hacks, systemd

My macbook running Arch Linux is currently having problems with the WiFi after resume from suspend. Systemd provides a mechanism to run executable files before and after suspend or hibernation. /usr/lib/systemd/system-sleep This mechanism relies on the system service systemd-suspend.service, this service will run all executable files in /usr/lib/systemd/system-sleep/. Two arguments are going to be passed to the script, before suspend the execution will look to something like: /usr/lib/systemd/system-sleep/wifi-hook.sh "pre" "suspend" After suspend, the execution will be: ...