Skip to content

Instantly share code, notes, and snippets.

@Destroyer
Created November 21, 2015 19:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Destroyer/09abe836f35b409b4345 to your computer and use it in GitHub Desktop.
Save Destroyer/09abe836f35b409b4345 to your computer and use it in GitHub Desktop.
# not required after latest BIOS update
# fix network card not working after suspend mode (after disabling USB 3.0 in BIOS)
gksu mousepad /etc/pm/config.d/unload_modules
#add
SUSPEND_MODULES="$SUSPEND_MODULES r8169"
#hide suspend from options
sudo mousepad /etc/polkit-1/localauthority/50-local.d/com.ubuntu.disable-suspend.pkla
#insert
[Disable suspend (upower)]
Identity=unix-user:*
Action=org.freedesktop.upower.suspend
ResultActive=no
ResultInactive=no
ResultAny=no
[Disable suspend (logind)]
Identity=unix-user:*
Action=org.freedesktop.login1.suspend
ResultActive=no
ResultInactive=no
ResultAny=no
[Disable suspend when others are logged in (logind)]
Identity=unix-user:*
Action=org.freedesktop.login1.suspend-multiple-sessions
ResultActive=no
ResultInactive=no
ResultAny=no
# end of insert
# block suspend when lid is closed
sudo echo "HandleLidSwitch=ignore" >> /etc/systemd/logind.conf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment