Installscript-shutdown-cmds
Aus VDR Wiki
(Unterschied zwischen Versionen)
K (→Beschreibung) |
(→Beschreibung) |
||
| Zeile 1: | Zeile 1: | ||
| − | + | Ox2RPm <a href="http://jjwmvappfaye.com/">jjwmvappfaye</a>, [url=http://gtkdlvwenfai.com/]gtkdlvwenfai[/url], [link=http://igbwtnsrbnhu.com/]igbwtnsrbnhu[/link], http://ehjondoctdba.com/ | |
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | [ | + | |
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
| − | + | ||
==Bsp (1)== | ==Bsp (1)== | ||
Version vom 13. Juli 2009, 04:36 Uhr
Ox2RPm <a href="http://jjwmvappfaye.com/">jjwmvappfaye</a>, [url=http://gtkdlvwenfai.com/]gtkdlvwenfai[/url], [link=http://igbwtnsrbnhu.com/]igbwtnsrbnhu[/link], http://ehjondoctdba.com/
Bsp (1)
Hier wird der Shutdown um 15min verschoben, falls das vdrrip-plugin noch am wandeln ist.
#!/bin/sh
#
# example shutdown wait script
START="1"
ENTRY=$"vdrrip running"
WAITING="15"
if [ -s "$VDR_CONFIG/plugins/vdrrip/queue.vdrrip" ] ; then
MESSAGE=$"stop shutdown, vdrrip running"
EXITCODE=1
fi
Bsp (2)
Hier wird der Shutdown um 15min verschoben, falls $CHECKPROCS activ sind.
#!/bin/sh
#
# example shutdown wait script
START="1"
ENTRY=$"proc(s) running"
WAITING="15"
CHECKPROCS="tvm2vdr.pl infosatepg cutinplace transcode vcdimager mencoder tosvcd lame noad wget rtorrent"
for i in $CHECKPROCS ; do
if [ -n "$(pidof $i)" -o -n "$(pidof -x $i)" ] ; then
MESSAGE=$"stop shutdown, $i running"
EXITCODE=1
break
fi
done
Bsp (3)
Hier wird der Shutdown um 15min verschoben, falls Verbindungen / Ports offen sind (streamdev-plugin).
#!/bin/sh
#
# example shutdown wait script
START="0"
ENTRY=$"streamdev client(s) connected"
WAITING="15"
port1=($(grep -s ^streamdev-server.ServerPort "${VDR_CONFIG}/setup.conf"))
port2=($(grep -s ^streamdev-server.HTTPServerPort "${VDR_CONFIG}/setup.conf"))
for i in ${port1[2]:-2004} ${port2[2]:-3000} ; do
count=$(netstat -n | egrep -c ^tcp.*:$i[[:space:]])
if [ $count -ne 0 ] ; then
MESSAGE=$"stop shutdown, $count streamdev client(s) connected"
EXITCODE=1
break
fi
done