blob: 60f813f2c70e35c0010425cdbae9b261e2f8f364 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
#!/sbin/runscript
depend() {
need net
}
start() {
ebegin "Starting nsca"
start-stop-daemon --start --quiet --name nsca \
--startas /usr/nagios/bin/nsca \
-c nagios:nagios \
-- -c /etc/nagios/nsca.cfg \
--daemon
eend $? "Failed to Start nsca"
}
stop() {
ebegin "Stopping nsca"
start-stop-daemon --stop --quiet -n nsca
eend $? "Failed to Stop nsca"
}
restart() {
ebegin "Restarting nsca"
svc_stop
svc_start
eend $? "Failed to Restart nsca"
}
|