Mailing List archive

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

[vdr] start by system-v script



hi ml,

i'm currently trying to switch from vdr-1.04-aio to vanilla vdr-1.1.x, but
one strange behaviour is still a show stopper:
started at system-start by a system-v script, only version 1.04 accepts
tty1 as stdin, vdr-1.1.27 doesn't even
request the key setup ( if remote.conf doesn't exist ).
started _from shell_ both do work flawless, it's just vdr-1.1.27's
non-interactive start on tty1.
/var/log/messages does indicate a normal start, it even switches to last
tv-channel and runs in background as usual.
started from shell, all keys get grabbed on tty1, but started from script,
all keys appear on the ( non-login ) console.

i don't have a working irda system setup yet, so testing with a remote is
not yet an option... but don't want to depend solely on it anyway.

short:
'/etc/init.d/vdr-1.0.x start' works
'/etc/init.d/vdr-1.0.x stop'
'/etc/init.d/vdr-1.1.x start' doesn't work

'/opt/vdr-1.1.27/bin/vdr --config=/opt/vdr-1.1.27/etc/
--epgfile=/mnt/tmpfs/epg.data 
--shutdown=/opt/scripts/system_shutdown  --terminal=/dev/tty1
--video=/home/media/dvb &'
works as did vdr-1.04

probably it's a bug in vdr-1.1.x, or maybe a dropped feature...
is there a helpful soul that can enlighten me? anyone?

bye,
daniel



p.s.:

root@streamer:~# view /etc/init.d/vdr-1.1.x
#!/bin/sh
#
# startup script for the 'video disc recorder' and its drivers
#
# description: video disc recorder dumps your dvb streams on disc
#

DAEMON="/opt/vdr-1.1.27/bin/vdr"
ARGS="--config=/opt/vdr-1.1.27/etc/ --epgfile=/mnt/tmpfs/epg.data
--shutdown=/op
t/scripts/system_shutdown --terminal=/dev/tty1 --video=/home/media/dvb"

## modules of driver version 1.0.0-preX
MODULES="dvb-ttpci evdev ves1820 stv0299 grundig_29504-491
grundig_29504-401 alp
s_tdlb7 alps_tdmb7 alps_bsrv2 dvb-core videodev"


test -f $DAEMON || exit 0

case "$1" in
  start)
        echo "loading 'digital video broadcast driver'"
        make -C /opt/dvb-2003_04_13/driver insmod 2>&1 > /dev/null
        echo "."
        echo -n "starting 'video disc recorder' daemon: vdr"
        start-stop-daemon --start --quiet --pidfile /var/run/vdr.pid \
                --chuid=root:root \
                --exec $DAEMON --background -- $ARGS
        echo "."
        ## give vdr time to fork, so that its pids are in a nicer
sequence
        sleep 1
        ;;
  stop)
        echo "stopping 'video disc recorder' daemon: vdr"
        start-stop-daemon --stop --quiet --pidfile /var/run/vdr.pid \
                --exec $DAEMON
        ## as there's no pidfile created yet clean up behind
        killall -TERM vdr
        ## give vdr time to finish
        sleep 2
        ## if vdr has crashed kill him
        killall -KILL vdr
        echo "."
        echo "deloading 'digital video broadcast driver'"
        modprobe -r $MODULES
        echo "."
        ;;
  restart|force-reload)
        echo "stopping 'video disc recorder' daemon: vdr"
        start-stop-daemon --stop --quiet --pidfile /var/run/vdr.pid \
                --exec $DAEMON
        ## as there's no pidfile created yet clean up behind
        killall -TERM vdr
        ## give vdr time to finish
        sleep 2
        ## if vdr has crashed kill him
        killall -KILL vdr
        echo "."
        echo "deloading 'digital video broadcast driver'"
        modprobe -r $MODULES
        rm -rf /dev/ost
        rm -rf /dev/ost
        echo "."

        echo "loading 'digital video broadcast driver'"
        make -C /opt/dvb-2003_04_13/driver insmod 2>&1 > /dev/null
        echo "."
        echo -n "starting 'video disc recorder' daemon: vdr"
        start-stop-daemon --start --quiet --pidfile /var/run/vdr.pid \
                --chuid=root:root \
                --exec $DAEMON --background -- $ARGS
        echo "."
        ## give vdr time to fork, so that its pids are in a nicer
sequence
        sleep 1
        ;;
  *)
        echo "Usage: $0 {start|stop|restart|force-reload}"
        exit 1
        ;;


-- 
Info:
To unsubscribe send a mail to listar@linuxtv.org with "unsubscribe vdr" as subject.



Home | Main Index | Thread Index