Corrections to spec file and scripts and update to the micasad.
CASA.spec and CASA_dbg.spec were synched up.
This commit is contained in:
@@ -35,9 +35,8 @@ case "$1" in
|
||||
# Remember status and be verbose
|
||||
rc_status -v
|
||||
;;
|
||||
|
||||
stop)
|
||||
echo "Shutting miCASA daemon down"
|
||||
echo "Shutting down micasad "
|
||||
#killproc -TERM $MICASAD_BIN
|
||||
pid=`cat /var/run/micasad.pid` >/dev/null 2>&1
|
||||
kill -s TERM $pid >/dev/null 2>&1
|
||||
@@ -45,12 +44,17 @@ case "$1" in
|
||||
# Remember status and be verbose
|
||||
rc_status -v
|
||||
;;
|
||||
|
||||
try-restart|condrestart)
|
||||
$0 status >/dev/null && $0 restart
|
||||
rc_status
|
||||
;;
|
||||
|
||||
$0 status
|
||||
if test $? = 0
|
||||
then
|
||||
$0 restart
|
||||
else
|
||||
rc_reset # Not running is not a failure.
|
||||
fi
|
||||
# Remember status and be quiet
|
||||
rc_status
|
||||
;;
|
||||
restart)
|
||||
## Stop the service and regardless of whether it was
|
||||
## running or not, start it again.
|
||||
@@ -61,34 +65,28 @@ case "$1" in
|
||||
# Remember status and be quiet
|
||||
rc_status
|
||||
;;
|
||||
|
||||
status)
|
||||
echo "Checking for service micasad ..."
|
||||
echo "Checking micasad service ..."
|
||||
/sbin/checkproc micasad
|
||||
$res=$?
|
||||
res=$?
|
||||
if [ $res == 0 ]
|
||||
then
|
||||
echo -n "0 - service up and running"
|
||||
elif [ $res == 1 ]
|
||||
then
|
||||
echo -n "1 - service dead, but /var/run/pid file exists"
|
||||
echo -n "1 - service running under mono, /var/run/pid file exists"
|
||||
elif [ $res == 2 ]
|
||||
then
|
||||
echo -n "2 - service dead, but /var/lock/lock file exists"
|
||||
echo -n "2 - service status unknown, /var/lock/lock file exists"
|
||||
elif [ $res == 3 ]
|
||||
then
|
||||
echo -n "3 - service not running (unused)"
|
||||
elif [ $res == 4 ]
|
||||
then
|
||||
echo -n "4 - service status unknown"
|
||||
echo -n "3 - service not running"
|
||||
else
|
||||
echo -n "5--199 reserved (5--99 LSB, 100--149 distro, 150--199 appl.)"
|
||||
echo -n "service status unknown"
|
||||
fi
|
||||
|
||||
rc_status >/dev/null 2>&1
|
||||
|
||||
rc_status -v
|
||||
;;
|
||||
|
||||
*)
|
||||
echo "Usage: $0 {start|stop|restart|try-restart|status}"
|
||||
exit 1
|
||||
|
||||
Reference in New Issue
Block a user