6 CTL
=/usr
/sbin
/ejabberdctl
7 DEFAULT
=/etc
/default
/ejabberd
9 RUNDIR
=/var
/run
/ejabberd
11 # Read default configuration file if present.
12 [ -r "$DEFAULT" ] && .
"$DEFAULT"
16 install -d -o "$INSTALLUSER" -g "$INSTALLUSER" "$RUNDIR"
22 printf "Starting ejabberd... "
24 # Wait until ejabberd is up and running.
25 if "$CTL" started
; then
32 printf "Stopping ejabberd... "
33 "$CTL" stop
> /dev
/null
34 if [ $?
-eq 3 ] ||
"$CTL" stopped
; then
52 echo "Usage: $0 {start|stop|status|restart|force-reload|live}"