3 PATH
=/usr
/sbin
:/usr
/bin
:/sbin
:/bin
:/opt
/java
/jre
/bin
6 PIDFILE
=/var
/run
/$NAME.pid
7 DAEMON
=/var
/subsonic
/subsonic.sh
8 DAEMON_ARGS
="--pidfile=$PIDFILE"
13 PID
=$
(ps ax |
grep java |
grep subsonic |
awk '{ print $1 }')
16 if [ ! -z "$PID" ]; then
19 stat_busy
"Starting $NAME..."
20 $DAEMON $DAEMON_ARGS &>/dev
/null
31 stat_busy
"Stopping $NAME..."
32 if [ -a $PIDFILE ]; then
43 [ ! -z "$PID" ] && kill $PID &> /dev
/null