CPU: Wrong CPU Load %.
[tomato.git] / release / src / router / ppp / scripts / ipv6-up.sample
blobe880445a65b5d19bdcbae44f4f2c102bf50089ac
1 #!/bin/sh
3 # This script is called with the following parameters:
4 # interface tty speed local-address remote-address ipparam
8 # Start router advertisements on this link.
9 # Based on radvd 0.5.0 behaviour
11 DEVICE=$1
13 CFGFILE=/usr/inet6/etc/radvd.conf-$DEVICE
14 PIDFILE=/var/run/radvd-$DEVICE.pid
16 if [ -x /usr/inet6/sbin/radvd && -f $CFGFILE ]; then
17 touch $PIDFILE
18 if [ ! -f $PIDFILE ]; then
19 echo "error: $PIDFILE is not a regular file. Aborting"
20 exit 0
23 PID=`cat $PIDFILE`
24 if [ "$PID" != "" ]; then
25 ps h $PID >/dev/null 2>&1 && exit 0
28 # radvd 0.5.0 doesn't write a pid-file so we do it here
29 # enabling debugging keeps radvd in foreground, putting it
30 # on background gives us the PID.
31 /usr/inet6/sbin/radvd -d 1 -C $CFGFILE &
32 echo $! >$PIDFILE