View Full Version : [Solved] TurnOff icon on desktop - bypass root password?
iX
May 24th 2011, 05:23 PM
How to create TurnOff icon on the desktop or in the quick launch ? - without sudo password needed?
There is command: shudown -h -now. But it needed root password.
how to bypass it? ::) (Like in K-Menu)
josefko
May 24th 2011, 06:18 PM
shutdown/lock plasmoid is not what are you looking for?
iX
May 24th 2011, 06:47 PM
Not exactly. ;D
It has Leave button - but I need my default action for leave = restart.
I want one - click button for TurnOff, another for LogOff, and for restart I have already ;).
josefko
May 24th 2011, 07:05 PM
You can create an icon this way, but still you are asked to set root password:
- Bring to plasma the widget Desktop if you do not have it
- Right click inside the window Desktop > Create New > Link to Application > Application > Command: shutdown .... > Advanced possibilities > Run as root
iX
May 24th 2011, 07:17 PM
Yes, this works, but the root pasword.... :( >:( ::) :-\ :'(
How they made it in kmenu?, there it dont want the pasw... ??? ???
josefko
May 24th 2011, 07:35 PM
So the title of the topic should be: How to bypass root password prompt?
I don't know, but I googled a little and found that you are not alone, it looks like it is necessary to change /etc/sudoerrs file, for example here http://ubuntuforums.org/showthread.php?t=478936
Ugly Dwarf
May 24th 2011, 08:34 PM
When searching the Kubuntu Forums with the "shutdown command kde4". One of the hits is: http://kubuntuforums.net/forums/index.php?topic=3103016.0. Maybe it will help ?
ubuntuku
May 24th 2011, 10:11 PM
Read here ;D: http://ubuntuku.org/32/how-to-create-a-desktop-shortcut-to-shutdown-turnoff-reboot-restart/
iX
May 25th 2011, 05:07 AM
Supr! :D This commands is what I need:
Shutdown:
qdbus --system org.freedesktop.ConsoleKit /org/freedesktop/ConsoleKit/Manager org.freedesktop.ConsoleKit.Manager.Stop
Restart:
qdbus --system org.freedesktop.ConsoleKit /org/freedesktop/ConsoleKit/Manager org.freedesktop.ConsoleKit.Manager.Restart
Now I am lookig for similar command for LogOut, I guess it must be something like this, but it dont work:
qdbus --system org.freedesktop.ConsoleKit /org/freedesktop/ConsoleKit/Manager org.freedesktop.ConsoleKit.Manager.Logout
???
iX
May 25th 2011, 05:33 AM
.... And found this:
LogOut:
qdbus org.kde.ksmserver /KSMServer logout 0 0 0
One problem resist: I use two panels - one at bottom of screen containing task manager and system tray, an second one at the top of screen containing quick launch widget, time, etc... But I am not able to add an icon from desktop to this top panel, I can only add icon to bottom panel using app-editor.
Is it possible to add icon to top panel?
iX
May 25th 2011, 05:43 AM
Finally! It want to reload desktop, now I have all needed icons where I want!
Thanks to all!!
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.