Forum

status option into the Debian init.d script

SaltwaterC
29 October 2009, 10:19
Hello,

I was kinda missing a status option into the startup script that some other already have. Here's a *sh function for this:

function status_hiawatha {
if [ -f $PIDFILE ] && ps `cat $PIDFILE` >/dev/null 2>&1; then
echo -e "${GREEN}Hiawatha is running...${NORMAL}"
return 0
else
echo -e "${RED}Hiawatha is not running...${NORMAL}"
return 1
fi
}

Regards.

Hiawatha version: 6.17.1
Operating System: Debian Lenny
Hugo Leisink
29 October 2009, 23:09
Looks oke. Will add it to the start/stop script. Thanks.
This topic has been closed.