blob: 6d5176c24428025569138888661519e1a897a57e (
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
29
30
31
32
33
34
35
36
37
38
39
40
|
#!/sbin/runscript
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/app-admin/metalog/files/metalog.initd,v 1.1 2006/12/30 04:06:49 vapier Exp $
opts="buffer unbuffer"
PIDFILE=/var/run/metalog.pid
depend() {
use clock hostname
provide logger
}
start() {
ebegin "Starting metalog"
/usr/sbin/metalog \
--daemonize \
--pidfile=${PIDFILE} \
${METALOG_OPTS}
eend $?
}
stop() {
ebegin "Stopping metalog"
start-stop-daemon --stop --quiet --pidfile ${PIDFILE}
eend $?
}
buffer() {
ebegin "Enabling log buffering"
kill -USR2 $(<${PIDFILE})
eend $?
}
unbuffer() {
ebegin "Disabling log buffering"
kill -USR1 $(<${PIDFILE})
eend $?
}
|