Re: VDR shutdown question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Norbert Goebel wrote:
> Hi,
> 
> does vdr (especially version 1.4.7 as I am using this right now) tell 
> the shutdownscript in any way what caused the shutdown-request (pressing 
> the poweroff button on fb or the idle timer)?
> 
[..]
> 
> For this it would be nice to have
> a) a direct vdr feature (like no idletimer from x to y (and maybe more 
> than one range)) or
> b) a way to distinguish between manual shutdown and idletimer shutdown 
> in the shutdownscript.

simply write an intelligent shutdownscript.


mine does:

(only snippets)

if [ "`ps aux | grep noad | grep -v 'grep noad'`" != "" ]; then
  logger -t vdr "not shutting down, noad is running"

if [ "`smbstatus -p | grep -c 192.168.42`" != "0" ]; then
  logger -t vdr "not shutting down, samba-users are connected"
  exit 1
  fi

if [ "`w -hs | wc -l`" != "0" ]; then
  logger -t vdr "not shutting down, users are connected"
  exit 1
  fi

simply do a timecheck. if its ok to shutdown, do it with an wakeuptime of $5 or if its a
manual shutdown without timer, with a wakeuptime of `date -d "tomorrow 8am" +"%s"`


you can script vdr very well, imho.

regards,
Friedhem.






_______________________________________________
vdr mailing list
vdr@xxxxxxxxxxx
http://www.linuxtv.org/cgi-bin/mailman/listinfo/vdr

[Index of Archives]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Util Linux NG]     [Xfree86]     [Big List of Linux Books]     [Fedora Users]     [Fedora Women]     [ALSA Devel]     [Linux USB]

  Powered by Linux