blob: 0d762c0430014f8f7f9593f475cedf864b126870 [file] [log] [blame]
paul15d74e92003-12-30 11:16:21 +00001#!/bin/bash
2#
3# chkconfig: 2345 16 84
4# description: An ISIS routing engine for use with Quagga
5#
6# processname: isisd
7# config: /etc/quagga/isisd.conf
8
9# source function library
10. /etc/rc.d/init.d/functions
11
12# Get network config
13. /etc/sysconfig/network
14
15# Check that networking is up.
16[ "${NETWORKING}" = "no" ] && exit 0
17
18# The process must be configured first.
19[ -f /etc/quagga/isisd.conf ] || exit 0
20
21RETVAL=0
22
23prog="isisd"
24
25case "$1" in
26 start)
27 echo -n $"Starting $prog: "
28 daemon /usr/sbin/isisd -d
29 RETVAL=$?
30 [ $RETVAL -eq 0 ] && touch /var/lock/subsys/isisd
31 echo
32 ;;
33 stop)
34 echo -n $"Shutting down $prog: "
35 killproc isisd
36 RETVAL=$?
37 [ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/isisd
38 echo
39 ;;
40 restart|reload)
41 $0 stop
42 $0 start
43 RETVAL=$?
44 ;;
45 condrestart)
46 if [ -f /var/lock/subsys/isisd ]; then
47 $0 stop
48 $0 start
49 fi
50 RETVAL=$?
51 ;;
52 status)
53 status isisd
54 RETVAL=$?
55 ;;
56 *)
57 echo $"Usage: $0 {start|stop|restart|reload|condrestart|status}"
58 exit 1
59esac
60
61exit $RETVAL