Skip to content

Instantly share code, notes, and snippets.

@nikhan
Last active June 27, 2018 07:02
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nikhan/b280697b0dd371776734fb350ff9a5c7 to your computer and use it in GitHub Desktop.
Save nikhan/b280697b0dd371776734fb350ff9a5c7 to your computer and use it in GitHub Desktop.
ubuntu/macbook 2015 - stop waking up upon suspend fix, as systemd unit
# ubuntu 17.04 / macbook pro retina 2015 13
#
# place in /etc/systemd/system
# systemctl daemon-reload
# systemctl enable nowake.service
# systemctl start nowake.service
#
# verify with `cat /proc/acpi/wakeup`
# XHC1 should be disabled
# disable more as needed
# keep LID0 enabled
[Unit]
Description=stop waking up after sleep macbook 2015
[Service]
ExecStart=/bin/bash -c "echo XHC1 > /proc/acpi/wakeup"
[Install]
WantedBy=multi-user.target
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment