Karmic various tricks

Logout messages

If you are opening a terminal to a different server or do a su in a terminal then on logout you will be required to enter your password in order to confirm the logout action. Since the polkit-gnome-authorization does not work with the new polkit version which ships with ubuntu and the polkit-auth command does not seems to work either I’ve found after some research that the solution resides in editing the /usr/share/polkit-1/actions/org.freedesktop.consolekit.policy file as follows:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE policyconfig PUBLIC
 "-//freedesktop//DTD PolicyKit Policy Configuration 1.0//EN"
 "http://www.freedesktop.org/standards/PolicyKit/1.0/policyconfig.dtd">

<policyconfig>

 <action id="org.freedesktop.consolekit.system.stop">
 <description>Stop the system</description>
 <message>System policy prevents stopping the system</message>
 <defaults>
 <allow_inactive>no</allow_inactive>
 <allow_active>yes</allow_active>
 </defaults>
 </action>

 <action id="org.freedesktop.consolekit.system.stop-multiple-users">
 <description>Stop the system when multiple users are logged in</description>
 <message>System policy prevents stopping the system when other users are logged in</message>
 <defaults>
 <allow_inactive>no</allow_inactive>
 <!--<allow_active>auth_admin_keep</allow_active>-->
 <allow_active>yes</allow_active>
 </defaults>
 </action>

 <action id="org.freedesktop.consolekit.system.restart">
 <description>Restart the system</description>
 <message>System policy prevents restarting the system</message>
 <defaults>
 <allow_inactive>no</allow_inactive>
 <allow_active>yes</allow_active>
 </defaults>
 </action>

 <action id="org.freedesktop.consolekit.system.restart-multiple-users">
 <description>Restart the system when multiple users are logged in</description>
 <message>System policy prevents restarting the system when other users are logged in</message>
 <defaults>
 <allow_inactive>no</allow_inactive>
 <!--<allow_active>auth_admin_keep</allow_active>-->
 <allow_active>yes</allow_active>
 </defaults>
 </action>

</policyconfig>

This allows the current user to perform actions related to the following policies:

  • org.freedesktop.consolekit.system.restart-multiple-users
  • org.freedesktop.consolekit.system.stop-multiple-user

Remove osd style popups

These popups which inform from connections success to battery status to pidgin messages can be a little annoying but they are quite easy to remove:

cd /usr/share/dbus-1/services/
sudo mv org.freedesktop.Notifications.service org.freedesktop.Notifications.service.disabled

You can revert the action to get the default behavior.

Related Posts with Thumbnails

Related posts:

  1. Ubuntu 9.10 Karmic Koala netbook I’ve also migrated my Acer Aspire One to the new...
  2. Ubuntu 9.10 Karmic Koala This ubuntu installation was the bit of fun expected after...
  3. Status RSS plugin for pidgin As a pidgin user I am used at not expecting...
  4. Eclipse crashes in Ubuntu Karmic Trying to run Apache Directory Studio I’ve found that eclupse...

10 Responses

  1. Thank you for the instructions! They worked perfectly!

    Alice

  2. [...] someone ponted me towards required edit. Tags: policykit, printing, [...]

  3. Many thanks. Instructions worked great.

  4. Exactly what I was looking for! Many thanks.

  5. I also did this worked perfectly

  6. Many thanks. This allows me to cleanly shut down my MythTV (MythBuntu) DVR system by pressing the computer’s power button.

  7. Thanks a lot!
    BTW do you know a way to disable consolekit? That useless thing runs 64 threads stealing memory (but not cpu) and I don’t want it on my machine.
    Unfortunately, xorg and other stuff depend on it, so I cannot simply uninstall it (network manager wouldn’t even start). But if I do a killall console-kit-daemon after booting is complete, then everything seems to work fine. Is there a way to disable it from config files?

  8. Sorry radix, I think google is your friend on this.

  9. [...] Rozwiązanie zaczerpnięte z http://www.len.ro/2009/11/karmic-various-tricks/ [...]

  10. [...] found a fix at Len’s site which solved my problem.  I am posting the modified org.freedesktop.consolekit.policy at my [...]

Leave a Reply