maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   General (https://talk.maemo.org/forumdisplay.php?f=7)
-   -   How to add a reboot button (https://talk.maemo.org/showthread.php?t=83691)

sifo 2012-04-16 21:11

How to add a reboot button
 
............... SORRY GOT TO REMOVE THIS :o

sifo 2012-04-17 19:50

Re: How to add a reboot button by-sifo
 
It Wont Hurt You Trying It :D

Mohammed Muid 2012-04-19 01:53

Re: How to add a reboot button by-sifo
 
i did try it. it worked. thanx :)

kent_autistic 2012-04-19 03:48

Re: How to add a reboot button by-sifo
 
i cant seem to get past the 3rd command line entry:


BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash)
Enter 'help' for a list of built-in commands.

~ $ sudo gainroot
Root shell enabled


BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash)
Enter 'help' for a list of built-in commands.

/home/user # echo "user ALL = NOPASSWD: /sbin/reboot"
user ALL = NOPASSWD: /sbin/reboot
/home/user # /etc/sudoers.d/reboot.sudoers
/bin/sh: /etc/sudoers.d/reboot.sudoers: not found
/home/user # /etc/sudoers.d/reboot.sudoers
/bin/sh: /etc/sudoers.d/reboot.sudoers: not found
/home/user # /etc/sudoers.d/reboot.sudoers
/bin/sh: /etc/sudoers.d/reboot.sudoers: not found
/home/user # /etc/sudoers.d/reboot.sudoers
/bin/sh: /etc/sudoers.d/reboot.sudoers: not found
/home/user #

nicolai 2012-04-19 07:21

Re: How to add a reboot button by-sifo
 
Can you explain to me why I need an extra dbus-service for this.
Why not just uncomment the already existing reboot entry
in systemui.xml?

And this does not work, you have to redirect the output
of the echo command.

Quote:

Originally Posted by sifo (Post 1192978)
> Next, lets modify the sudoers file to allow us running reboot:

> echo "user ALL = NOPASSWD: /sbin/reboot"

> /etc/sudoers.d/reboot.sudoers


> Update sudoers:


praveenchand 2012-04-19 07:24

Re: How to add a reboot button by-sifo
 
editing systemui.xml is the easiest way..

jedi 2012-04-19 07:31

Re: How to add a reboot button by-sifo
 
This is a better version: http://talk.maemo.org/showthread.php?t=48843 amongst others.

Am I alone in wondering what benefit there is of copy/pasting stuff from a blog to a forum post here? The info on the blog probably originated from here in the first place!

Dousan 2012-04-19 07:52

Re: How to add a reboot button by-sifo
 
Quote:

Originally Posted by jedi (Post 1194215)
Am I alone in wondering what benefit there is of copy/pasting stuff from a blog to a forum post here? The info on the blog probably originated from here in the first place!

No you're not, I was thinking the same thing, even more when also reading his other threads.
Maybe he want to boost his thanks meter?

Regards Dousan...

sifo 2012-04-19 13:40

Re: How to add a reboot button by-sifo
 
All right i tried to help new users but no problem im sorry i'll remove this just forgive all my mistakes over tmo

reinob 2012-04-19 13:43

Re: How to add a reboot button by-sifo
 
Quote:

Originally Posted by nicolai (Post 1194211)
Can you explain to me why I need an extra dbus-service for this.
Why not just uncomment the already existing reboot entry
in systemui.xml?

And this does not work, you have to redirect the output
of the echo command.

The guy is failing even to use copy & paste properly. Sigh..

Sourav.dubey 2012-04-19 13:55

Re: How to add a reboot button by-sifo
 
Quote:

Originally Posted by sifo (Post 1194350)
All right i tried to help new users but no problem im sorry i'll remove this just forgive all my mistakes over tmo

you are always welcome in TMO

you should solve new user problem in the existing thread
No need to create new threads

anyway your thinking behind all this is good

J4ZZ 2012-04-19 15:44

Re: How to add a reboot button by-sifo
 
Quote:

Originally Posted by nicolai (Post 1194211)
Can you explain to me why I need an extra dbus-service for this.
Why not just uncomment the already existing reboot entry
in systemui.xml?

Like the Note said:
some of you may notice that a reboot entry is already defined in systemui.xml. However, osso-powerup-shutdown performs a shutdown which kill all apps suddenly. Rebooting with sudo reboot will gently shutdown all software and sync your filesystem, which is safer. Lets just say that there was probably a reason that the default entry was commented out.

BTW: The source is here * The Truly Epic Maemo 5 MODs Thread *
Part 1
Part 2
both posted by good old qwerty12

Or the summary by MohammadAG

Code:

sudo gainroot
echo "user ALL = NOPASSWD: /sbin/reboot" > /etc/sudoers.d/reboot.sudoers
update-sudoers
nano /usr/share/dbus-1/services/reboot.service
# Paste this into it:
[D-BUS Service]
Name=com.misc.reboot
Exec=/usr/bin/sudo reboot
# CTRL + O to save, CTRL+X to quit nano
nano /etc/systemui/systemui.xml
# Paste this into it:
<menuitem priority="750" name="Reboot">
<icon>general_refresh</icon>
<callback service="com.misc.reboot" path="/com/misc/reboot" interface="com.misc.reboot" method="reboot" bus="session" autostart="true">
<argument type="boolean">true</argument>
</callback>
</menuitem>
# CTRL + O to save, CTRL+X to quit nano
killall systemui

Cheers,

J4ZZ

Mohammed Muid 2012-04-19 15:44

Re: How to add a reboot button by-sifo
 
doesnot reboot. i successfully added the reboot button by editing systemui. now i have two reboot buttons. one works and one doesnt (followed sifo's guide) how to remove it?

Dousan 2012-04-19 15:49

Re: How to add a reboot button by-sifo
 
Quote:

Originally Posted by Mohammed Muid (Post 1194432)
doesnot reboot. i successfully added the reboot button by editing systemui. now i have two reboot buttons. one works and one doesnt (followed sifo's guide) how to remove it?

Ask sifo :p ;)

Regards Dousan...

sifo 2012-04-19 15:51

Re: How to add a reboot button by-sifo
 
what mohammed you mean mine the one on the guide that i posted (took from the nokia n900 blog ) not working well it works with me!

Dousan 2012-04-19 16:06

Re: How to add a reboot button by-sifo
 
Quote:

Originally Posted by sifo (Post 1194443)
what mohammed you mean mine the one on the guide that i posted (took from the nokia n900 blog ) not working well it works with me!

Either way he's just asking how to remove it. Nothing else mate :)

Regards Dousan...

Mohammed Muid 2012-04-19 16:14

Re: How to add a reboot button by-sifo
 
how to remove it? help me to remove it. i dn care were u took it from mate. cheers

sifo 2012-04-19 17:12

Re: How to add a reboot button by-sifo
 
im not sure but try removing the files you created and the texts you add then redo the steps that might work somebody please correct me i im wrong !

Mohammed Muid 2012-04-19 17:17

Re: How to add a reboot button by-sifo
 
you removed the process of doing it. by reading that i could have removed the lines. u need to paste the tutorial again i gess

Sourav.dubey 2012-04-19 17:20

Re: How to add a reboot button by-sifo
 
Use the following link and undo every step
nokia-n900.com/how-to-adding-a-reboot-button-to-your-powerkey-menu/

you can also use filebox to do so

sifo 2012-04-19 17:41

Re: How to add a reboot button by-sifo
 
for sure this is the right thing to do follow the orginal post oR else if i paste it here again i'll get punshed :D AGAIN

J4ZZ 2012-04-19 22:45

Re: How to add a reboot button by-sifo
 
Quote:

Originally Posted by Mohammed Muid (Post 1194456)
how to remove it? help me to remove it. i dn care were u took it from mate. cheers

Easiest way,
open /etc/systemui/systemui.xml
Code:

nano /etc/systemui/systemui.xml
and remove the whole block
Code:

<menuitem priority="750" name="Reboot">
<icon>general_refresh</icon>
<callback service="com.misc.reboot" path="/com/misc/reboot" interface="com.misc.reboot" method="reboot" bus="session" autostart="true">
<argument type="boolean">true</argument>
</callback>
</menuitem>

or comment it out by adding

Code:

<!--
<menuitem priority="750" name="Reboot">
<icon>general_refresh</icon>
<callback service="com.misc.reboot" path="/com/misc/reboot" interface="com.misc.reboot" method="reboot" bus="session" autostart="true">
<argument type="boolean">true</argument>
</callback>
</menuitem>
-->

;)


All times are GMT. The time now is 16:38.

vBulletin® Version 3.8.8