6

I'm running Freya on a MacBook Pro 2013 edition.

Suspend doesn't ever work as planned. It takes quite a while to actually get to sleep and it'll often wake itself back up again, and when it does, it seems to have taken out the entire networking stack and neither my USB 3 Ethernet adapter nor my wireless USB dongle work any more.

The main problem is that it always suspends when the lid is closed, which I want to never happen.

Is there a way to fully prevent it from ever suspending? I'm using it with 2 DisplayPort monitors right now, but I can't close the lid for fear that it'll suspend itself and screw everything up.

2 Answers 2

1

You could install Caffeine from ppa:caffeine-developers/ppa.

It runs as an indicator and can be used to prevent suspension.

You can also try this method, taken from Ask Ubuntu:

For me it is important to just disable the "automatic Suspend" Because I still want to be able to do the "manual Suspend" in /etc/polkit-1/localauthority/50-local.d/com.ubuntu.disable-suspend.pkla

So, I used:

[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=yes
ResultInactive=no
ResultAny=yes

[Disable suspend when others are logged in (logind)]
Identity=unix-user:*
Action=org.freedesktop.login1.suspend-multiple-sessions
ResultActive=yes
ResultInactive=no
ResultAny=yes

Now I can click "Suspend" in the logoff menu. But the PC keeps running unless I send it to "Suspend".

5
  • Thanks for the tip, but I don't have that file on my computer. Nothing exists in 50-local.d. I'll look elsewhere. Commented Aug 3, 2015 at 18:59
  • @NaftuliTzviKay use locate from the command line to find the file.
    – RolandiXor
    Commented Aug 4, 2015 at 17:11
  • I did. There's nothing with a similar name. Commented Aug 4, 2015 at 17:11
  • You may have to create the file.
    – RolandiXor
    Commented Aug 4, 2015 at 17:12
  • Noted. I'll look into it. Commented Aug 4, 2015 at 17:12
1

I use elementary OS freya and there is a GUI app for powermanagement. Remove all instances of sleep, suspend and hibernate. You can leave turn the display off.

That disables automatical suspend, but will leave the manual suspend up in the menu in the right upper corner. Mbr Patte

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.