[Zebralist] zebra startup script

Weber Peter Peter.Weber at rero.ch
Fri Oct 19 16:07:28 CEST 2007


maybe not the nicest one which is working in UBUNTU:

#! /bin/sh
# zebra agent start/stop script.

DAEMON=/usr/local/bin/zebrasrv
NAME=zebra
DESC="Zebra server"
DATABASE=/zebra
CONF=/etc/zebra/zebra.xml
LOG=/var/log/zebra.log
PID=/var/run/zebra.pid
USER=zebra

test -f $DAEMON || exit 0

set -e

case "$1" in
   start)
         # rm -f $PID
         echo "Starting $DESC: $NAME"
         start-stop-daemon --oknodo --start --chuid $USER --chdir  
$DATABASE --pidfile $PID --exec $DAEMON
         ;;
   stop)
         echo "Stopping $DESC: $NAME"
         start-stop-daemon --oknodo --stop --exec $DAEMON
         ;;
   restart|force-reload)
         $0 stop
         $0 start
         ;;
   *)
         N=/etc/init.d/$NAME
         echo "Usage: $N {start|stop|restart|force-reload}" >&2
         exit 1
         ;;
esac

exit 0

On Oct 19, 2007, at 13:01, Eric Lease Morgan wrote:

>
> Does anybody here have a Zebra start, stop, status, restart script?
> You know, the sort of script that is run from /sbin/service and
> managed with things like chkconfig on Linux systems. I suppose I
> could write my own, but I'm too lazy.
>
> -- 
> Eric Lease Morgan
> University Libraries of Notre Dame
>
>
>
> _______________________________________________
> Zebralist mailing list
> Zebralist at lists.indexdata.dk
> http://lists.indexdata.dk/cgi-bin/mailman/listinfo/zebralist

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.indexdata.dk/pipermail/zebralist/attachments/20071019/b9f20eba/attachment.htm 


More information about the Zebralist mailing list