Handy Trick for Fedora 16 / Gnome 3 : Disable Suspend.

Update: March 2013: Fedora 18+

With Fedora 18 the situation (for me, at least) has become much better; both my netbook and desktop had ‘poweroff’ as I would expect in the menu after a default installation, and I did not need to do any of the steps listed below to get my expected operation.

Whether this is because of a change of Gnome policy, or better ACPI capabilities detection, I do not know; and don’t really care either since it is fixed for me :-P

But.. If you still have issues with Fedora18 you might want to use a shell extension to change the menu’s rather than messing with system settings: I suggest the ‘Frippery Shut Down Menu’ from here.

Original post follows:


This is dead simple; Gnome 3 tries to impose Suspend on users as the only true way(tm) to de-power their system; hiding PowerOff behind a modifier key. If suspend fails on your Fedora 16 Machine this is a constant source of irritation.

In short, to avoid a minor rant, suspend is quite a problem area for Linux and is broken on many common chipsets and systems. I have 2 Desktop machines and a NetBook all running Fedora 16, and suspend is broken on all of them, I suspect many others have a similar level of breakage.

Fortunately; the system policy framework on Linux is good; allowing us to simply tell the OS that Suspend is not available. :-)

UPDATED: The original solution given here worked but was substandard because it was not permanent. Updates to the polkit system would re-write the file we were modifying, leading to an ‘aaargh! dammit.’ moment.

Fortunately folks older and more into the inner workings of this stuff than me have a better, permanent, solution; so head on over to Anttix’s blog for a correct solution. :-)


Do not do the following, see above!

I owe a debt to ‘headkase’ on the Fedora Forums for this tip!

Edit the xml file:
/usr/share/polkit-1/actions/org.freedesktop.upower.policy
.. with your favorite text editor.

Find the XML definition section for suspend:

 <action id=”org.freedesktop.upower.suspend”>

<defaults>
<allow_inactive>no</allow_inactive>
<allow_active>yes</allow_active>
</defaults>
</action>

Ignore all the Description and Message fields; the bit we are interested in is the ‘allow_active‘ definition; change the ‘yes‘ to ‘no‘.

 <allow_active>no</allow_active>

Save the file (you did edit it as root.. yes? ;-) ) and reboot.

Once you have done that Gnome 3 does the correct thing and replaces the Suspend default menu entry with PowerOff. And one of life’s little irritations is now solved; If you have a laptop you might also want to use the Advanced Configuration editor (Part of the ‘gnome-tweak-tool‘ package) to modify behaviour when the lid is closed.

  • Digg
  • StumbleUpon
  • del.icio.us
  • Facebook
  • Twitter
  • Google Bookmarks
  • Add to favorites

4 comments to Handy Trick for Fedora 16 / Gnome 3 : Disable Suspend.

Leave a Reply

  

  

  

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Protected with IP Blacklist CloudIP Blacklist Cloud