Disable hibernate/suspend

Archived topics about LMDE 2
Locked
mbod
Level 1
Level 1
Posts: 18
Joined: Wed Sep 12, 2012 9:50 am

Disable hibernate/suspend

Post by mbod » Fri Mar 04, 2016 8:32 am

Hi,

I am looking for a way to remove the Hibernate/Suspend options from the MDM menu and from the cinnamon shutdown dialog.
I only want to see the options poweroff and reboot.

How do I do that?

Matthias

User avatar
Crewp
Level 9
Level 9
Posts: 2517
Joined: Sat Dec 01, 2012 8:36 pm
Location: Connecticut,USA

Re: Disable hibernate/suspend

Post by Crewp » Fri Mar 04, 2016 8:50 am

Try this, I hope it helps.

In the terminal, type:

Code: Select all

sudo systemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.target
Image

User avatar
Pjotr
Level 21
Level 21
Posts: 13863
Joined: Mon Mar 07, 2011 10:18 am
Location: The Netherlands (Holland)
Contact:

Re: Disable hibernate/suspend

Post by Pjotr » Fri Mar 04, 2016 10:00 am

This is a tried and tested way to do that:
https://sites.google.com/site/easylinux ... ter-a-coma
(item 9, left column)

Guaranteed to work. :)
Tip: 10 things to do after installing Linux Mint 19.2 Tina
Keep your Linux Mint healthy: Avoid these 10 fatal mistakes
Twitter: twitter.com/easylinuxtips
All in all, horse sense simply makes sense.

mbod
Level 1
Level 1
Posts: 18
Joined: Wed Sep 12, 2012 9:50 am

Re: Disable hibernate/suspend

Post by mbod » Fri Mar 04, 2016 2:13 pm

I am sorry to say that, but I think you are both wrong. :(

@Crewp:
LMDE does not ship with systemd. In that regard it is deviating from debian stable. Therefor your proposal with masking services via systemctl does not work.

@Pjotr,

the tutorial you linked to is for Ubuntu based Mint. in LMDE2 there is no such file: /etc/polkit-1/localauthority/50-local.d/com.ubuntu.enable-hibernate.pkla

Any other idea?

Matthias

User avatar
Crewp
Level 9
Level 9
Posts: 2517
Joined: Sat Dec 01, 2012 8:36 pm
Location: Connecticut,USA

Re: Disable hibernate/suspend

Post by Crewp » Fri Mar 04, 2016 2:52 pm

you are correct, sorry.
Image

User avatar
killer de bug
Level 14
Level 14
Posts: 5415
Joined: Tue Jul 08, 2008 1:49 pm
Location: Leuven, Belgium

Re: Disable hibernate/suspend

Post by killer de bug » Fri Mar 04, 2016 4:40 pm

The solution given here may work: viewtopic.php?f=239&t=197339

For you, it should be

Code: Select all

gsettings set org.cinnamon.desktop.session session-manager-uses-logind fasle
If it ain't broke, fix it until it is.

User avatar
Pjotr
Level 21
Level 21
Posts: 13863
Joined: Mon Mar 07, 2011 10:18 am
Location: The Netherlands (Holland)
Contact:

Re: Disable hibernate/suspend

Post by Pjotr » Fri Mar 04, 2016 5:20 pm

mbod wrote:the tutorial you linked to is for Ubuntu based Mint. in LMDE2 there is no such file: /etc/polkit-1/localauthority/50-local.d/com.ubuntu.enable-hibernate.pkla
You're right: I overlooked the fact that you have LMDE2.... :P
Tip: 10 things to do after installing Linux Mint 19.2 Tina
Keep your Linux Mint healthy: Avoid these 10 fatal mistakes
Twitter: twitter.com/easylinuxtips
All in all, horse sense simply makes sense.

User avatar
killer de bug
Level 14
Level 14
Posts: 5415
Joined: Tue Jul 08, 2008 1:49 pm
Location: Leuven, Belgium

Re: Disable hibernate/suspend

Post by killer de bug » Fri Mar 04, 2016 5:24 pm

Pjotr wrote: You're right: I overlooked the fact that you have LMDE2.... :P
That's actually the purpose of the LMDE section :mrgreen:
If it ain't broke, fix it until it is.

mbod
Level 1
Level 1
Posts: 18
Joined: Wed Sep 12, 2012 9:50 am

Re: Disable hibernate/suspend

Post by mbod » Fri Mar 04, 2016 6:46 pm

Code: Select all

gsettings set org.cinnamon.desktop.session session-manager-uses-logind fasle
So that works for me at least for the cinnamon logout dialog. Thank you!

But it does not change the MDM menu. Any idea for that?

Matthias

mbod
Level 1
Level 1
Posts: 18
Joined: Wed Sep 12, 2012 9:50 am

Re: Disable hibernate/suspend

Post by mbod » Sat Mar 05, 2016 4:42 am

mbod wrote:

Code: Select all

gsettings set org.cinnamon.desktop.session session-manager-uses-logind fasle
So that works for me at least for the cinnamon logout dialog. Thank you!
But how do I make this seting global? Currently it is only active for my user.

Matthias

franute
Level 1
Level 1
Posts: 11
Joined: Tue Jun 28, 2011 9:47 am

Re: Disable hibernate/suspend

Post by franute » Fri Mar 11, 2016 7:22 am

I have followed this in LMDE2 to disable hibernate (useless with SSDs) and worked like a charm:

https://sites.google.com/site/easytipsf ... nd-suspend

Hope this helps :)

mbod
Level 1
Level 1
Posts: 18
Joined: Wed Sep 12, 2012 9:50 am

Re: Disable hibernate/suspend

Post by mbod » Sun Mar 13, 2016 10:27 am

Hello farnute,

that works at least for cinnamon. Thanks.

But mdm still shows "Bereitschaft" = suspend in the menu.

Matthias

Locked

Return to “LMDE 2 "Betsy" Archive”