-----Ursprüngliche Nachricht (HTML) wurde als Anlage beigefügt.-----
Von:      freevo-users@lists.sourceforge.net
Gesendet: 29.05.05 10:07:33
An:       "Tanja Striepling" <[EMAIL PROTECTED]>
Betreff:  Re: [Freevo-users] Re: new plugin for freevo1.5.3: automatic shutdown 
and wakeup

Thanks for your answer. 
Good to hear that it is working.
I will change the information in the wiki 
and put the complete version of wakeupshutdown online...

Greetings
Tanja
__________________________________________________________
Mit WEB.DE FreePhone mit hoechster Qualitaet ab 0 Ct./Min.
weltweit telefonieren! http://freephone.web.de/?mc=021201
Title: freevo-users@lists.sourceforge.net schrieb am 29.05.05 10:07:33
-----Ursprüngliche Nachricht wurde als Attachment angehängt.-----
Von:freevo-users@lists.sourceforge.net
Gesendet:29.05.05 10:07:33
An:"Tanja Striepling" <[EMAIL PROTECTED]>
Betreff:Re: [Freevo-users] Re: new plugin for freevo1.5.3: automatic shutdown and wakeup
Tanja Striepling wrote:
How to use this with nvram, readme only says just put the path to  nvram-wakeup in WAKEUP_CMD.   local.conf WAKEUP_METHODE = 'nvram' # you also need root permissions for this, so you may need to use sudo  here, too WAKEUP_CMD = 'sudo /usr/sbin/nvram-wakeup'  what I need is reboot echo "savedefault --default=1 --once quit" | sudo /sbin/grub --batch  --device-map=/boot/grub/device.map and nvram-wakeup --directisa  now freevo only shutdown...  Thanks      
 Sorry, I do not use nvram-wakeup, so I never tested that part.  It is copied and pasted from some earlier work of Hans Meine. I just checked that code again and found that I forgot to include one helper that is needed for the reboot. Sorry! I now included it in the new version of the package.  The nvram-wakeup part works, -or as least should work like,-  this:  1) When nvram-wakeup is called to configure the nvram for the new wakeup, the exit code is checked 2) If the exit code of nvram is 256,  then the bios needs a reboot 3) A file is written to the freevo cache dir as a flag that this is a reboot  which should be followed by a complete shutdown 4) The system is not shutdown but rebooted instead 5) When the system is booting again, the rebootflag helper (which is now included with the package) checks for the flag. 6) If it finds the flag,  it removes the flag and shuts down the system this time completly 7) If it does not find the flag, than this is a real boot and not just a reboot, the helper is doing nothing then  So you need to run the rebootflag helper in one of your startup scripts. Just copy rebootflag.py to /path/to/your/freevo/src/helper and run it as freevo reboot  There is also some help available when you call freevo reboot --help.  I am sorry, but you are in the unhappy position to be the first person to  test the nvram part. :-( Run freevo with DEBUG=1 and have a look at the logs. There should be messages as like what command is called for nvram-wakeup  and what the exit code was....  I hope you get this running.  Feel free to send more questions or maybe even suggestions for improvement.  Greetings Tanja                            ______________________________________________________________ Verschicken Sie romantische, coole und witzige Bilder per SMS! Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193
Thanks...

Your wakeup is up and running with nvram.

here is my local_conf.py

# Wakeup
# To make use of this plugin you must allow a system shutdown from freevos menu
# ENABLE_SHUTDOWN_SYS = 1
# If you enable this, you will get a warning about running or soon starting
# recordings when you choose to shutdown the system (recommended)
CONFIRM_SHUTDOWN    = 1
# if you do not run freevo as root, you must use sudo for the shutdown commands
SHUTDOWN_SYS_CMD="/usr/local/bin/shutdown.sh"
RESTART_SYS_CMD  = 'sudo shutdown -r now'
# choose your wakeup methode here:
WAKEUP_METHODE = 'nvram'
# you also need root permissions for this, so you may need to use sudo here, too
WAKEUP_CMD = 'sudo nvram-wakeup -A'
# time your system needs for the boot process
BOOTTIME_PADDING = 180

and shutdown.sh

#!/bin/bash
echo "savedefault --default=1 --once quit" | sudo /sbin/grub --batch --device-map=/boot/grub/device.map
# perform reboot now !
sudo /sbin/shutdown -r now

Is there any way  to use a rebootflag helper to write that grub or lilo stuff. Like adding extra line in local_conf.
GRUB = 'echo "savedefault --default=1 --once quit" | sudo /sbin/grub --batch --device-map=/boot/grub/device.map'

and nice extra feature to wakeup machine after four days example to update  xmltv data.









 







Reply via email to