3 # chkconfig: 2345 56 25
4 # description: planetflow slice initscript
7 #. /etc/rc.d/init.d/functions
9 DELTA=10 # Time to sleep between polls
10 VSYSSCRIPT="/vsys/pfmount.in"
15 # if the file exists, try writing to it.
16 if [ -a ${VSYSSCRIPT} ]; then
17 echo "Writing to Fifo"
18 /bin/echo ${VSYSCMD} > ${VSYSSCRIPT} &
20 # Wait for command to complete
22 # check to see if PID is running
23 if kill -0 ${PID} >/dev/null 2>&1 ; then
24 # if PID is running, it's likely hung. Kill it.
25 echo "Blocked on Fifo. Killing"
28 # assume if PID is no longer, command completed
29 echo "Completed. Exitting"
33 # no pipe yet. vsys probably hasn't started yet. wait.
34 echo "${VSYSSCRIPT} doesn't exist"
43 echo -n "starting the planetflow slice:"
48 echo "Usage: $0 {start|stop|restart|status}"