3 # Start & stop the inadyn client
6 CONFIG
=/etc
/inadyn.conf
7 VR_INADYN
=/var
/run
/inadyn
9 # check if CONFIG exists, print message & exit if it doesn't
10 [ ! -f $CONFIG ] && ( echo "The config file "$CONFIG" is missing...exiting now." && exit 2 )
12 # check if VR_INADYN exists, create it if not
13 [ ! -d $VR_INADYN ] && mkdir
-p $VR_INADYN
17 echo "Starting inadyn: "
18 start-stop-daemon
-S -x /usr
/bin
/inadyn
19 [ $?
= 0 ] && echo "OK" ||
echo "FAIL"
22 echo "Stopping inadyn: "
23 start-stop-daemon
-q -K -x /usr
/bin
/inadyn
24 [ $?
= 0 ] && echo "OK" ||
echo "FAIL"
25 rm -f /var
/run
/inadyn
/inadyn.pid
32 echo "Usage: $0 {start|stop|restart}"