]>
git.ipfire.org Git - thirdparty/bird.git/blob - misc/bird.init
3 # bird Starts the Internet Routing Daemon.
5 # Author: Ondrej Feela Filip, <feela@network.cz>
8 # description: Internet routing daemon supporting IPv4 routing protocols:
9 # BGP4, RIPv2 and OSPFv2.
12 # config: /etc/bird.conf
15 # Source function library.
16 .
/etc
/rc.d
/init.d
/functions
18 [ -f /etc
/sysconfig
/network
] ||
exit 0
20 .
/etc
/sysconfig
/network
28 [ -f /etc
/bird.conf
] || BIRD4
="no"
29 [ -f /usr
/sbin
/bird
] || BIRD4
="no"
30 [ "${NETWORKING}" = "yes" ] || BIRD4
="no"
32 [ -f /etc
/bird6.conf
] || BIRD6
="no"
33 [ -f /usr
/sbin
/bird6
] || BIRD6
="no"
34 [ "${NETWORKING_IPV6}" = "yes" ] || BIRD6
="no"
36 [ -e /etc
/sysconfig
/bird
] && .
/etc
/sysconfig
/bird
40 # See how we were called.
43 if [ "$BIRD4" = "yes" ]
45 echo -n "Starting BIRD for IPv4: "
46 daemon bird
${BIRD4ARGS}
49 [ $RETVAL -eq 0 ] && touch /var
/lock
/subsys
/bird
51 if [ "$BIRD6" = "yes" ]
53 echo -n "Starting BIRD for IPv6: "
54 daemon bird6
${BIRD6ARGS}
57 [ $RETVAL -eq 0 ] && touch /var
/lock
/subsys
/bird6
61 echo -n "Stopping BIRD for IPv4: "
65 [ $RETVAL -eq 0 ] && rm -f /var
/lock
/subsys
/bird
67 echo -n "Stopping BIRD for IPv6: "
71 [ $RETVAL -eq 0 ] && rm -f /var
/lock
/subsys
/bird6
87 echo -n "Reloading BIRD for IPv6: "
93 echo "Usage: bird.init {start|stop|status|restart|reload}"