Ticket #611: bind.sh
File bind.sh, 389 bytes (added by bchesneau@…, 21 years ago) |
---|
Line | |
---|---|
1 | #!/bin/sh |
2 | |
3 | PIDFILE=named.pid |
4 | CAT=/bin/cat |
5 | KILL=/bin/kill |
6 | |
7 | case "$1" in |
8 | |
9 | start) |
10 | echo "starting bind" |
11 | %%PREFIX%%/sbin/named |
12 | ;; |
13 | |
14 | restart) |
15 | echo "restarting bind" |
16 | $KILL -HUP `$CAT %%PREFIX%%/var/run/$PIDFILE` |
17 | ;; |
18 | |
19 | stop) |
20 | echo "stopping bind" |
21 | $KILL -15 `$CAT %%PREFIX%%/var/run/$PIDFILE` |
22 | ;; |
23 | |
24 | *) |
25 | echo "Usage: %%PREFIX%%/etc/rc.d/bind {start|stop|restart}" |
26 | exit 1 |
27 | ;; |
28 | |
29 | esac |