5

I get following error when I try to suspend my laptop:

failed to check authorisation: 
GDBus.Error:org.freedesktop.DBus.Error.Service.Unknown:
The name org.freedesktop.PolicyKit1 was not provided by any .service files 

Which I understand as telling me that PolicyKit is not installed. The problem is, on my second laptop, which has identical OS and almost identical HW, suspend works fine without PolicyKit.

I know I could fix my problem by installing the policykit-1 package, but I am wondering whether PolicyKit is necessary for suspend to work - obviously not, because it works without on my other laptop.

I have no idea how PolicyKit is supposed to work. For reasons beyond this discussion, I would very much like to avoid having to install it.

Can I use suspend without having to install policyKit ?

I am using Debian Wheezy and LXDE

The other commands: "Shutdown" and "Restart" work fine. Also, my user is in group powerdev:

powerdev:x:108:martin

By "suspend", I mean "suspend to RAM".

3
  • Following. I have a similar issue although PolicyKit is installed: unix.stackexchange.com/questions/158494/…
    – a coder
    Oct 1, 2014 at 16:07
  • What groups is your user in on the 2 systems? The cmd. id -a on each system as the user that owns the desktop.
    – slm
    Oct 1, 2014 at 23:42
  • @slm - id -a gives the same output on both systems: uid=1000(martin) gid=1000(martin) groups=1000(martin),29(audio),108(powerdev) Oct 2, 2014 at 0:30

2 Answers 2

2

I suspect you are using systemd. If that is true then use its built-in tool systemctl:

systemctl suspend
systemctl hibernate
systemctl hybrid-sleep
systemctl reboot
systemctl poweroff
systemctl halt

As always you can create an alias for any of these commands.

1
  • 1
    no, no, no. I am not using systemd (and I never will) Oct 2, 2014 at 22:04
1

What about pm-utils?

Typing pm-suspend at the console suspends on demand.

You can install both acpid and acpi-support to sleep your laptop when you close the lid. You have to uncomment LID_SLEEP=true in /etc/default/acpi-support to get the lid working.

It did not require policykit-1 for me, but for full disclosure I am on jessie.

2
  • I have pm-utils installed and pm-suspend from console works OK. But still I have the problem when using the "Suspend" button from the "Logout" menu in LXDE. Oct 1, 2014 at 17:06
  • 1
    @MartinVegter - Regarding your other computer that does suspend: is it possible to do dpkg --get-selections > working_computer.txt and dpkg --get-selections > not_working_computer.txt; then get the two files in the same directory, and do diff working_computer.txt not_working_computer.txt? That will tell you what is installed on one machine but not the other. Then you may be able to narrow down the troublesome packages. Oct 1, 2014 at 17:24

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .