From: | "Diego Petteno (flameeyes)" <flameeyes@g.o> |
---|---|
To: | gentoo-commits@l.g.o |
Subject: | [gentoo-commits] gentoo-x86 commit in net-analyzer/munin/files: munin-node_init.d_1.4.5-r3 |
Date: | Sun, 03 Apr 2011 22:16:00 |
Message-Id: | 20110403221550.2827B20057@flycatcher.gentoo.org |
1 | flameeyes 11/04/03 22:15:50 |
2 | |
3 | Modified: munin-node_init.d_1.4.5-r3 |
4 | Log: |
5 | Create /var/run/munin if it's missing, otherwise munin-node will not start (and will do that silently). |
6 | |
7 | (Portage version: 2.2.0_alpha29/cvs/Linux x86_64) |
8 | |
9 | Revision Changes Path |
10 | 1.2 net-analyzer/munin/files/munin-node_init.d_1.4.5-r3 |
11 | |
12 | file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-analyzer/munin/files/munin-node_init.d_1.4.5-r3?rev=1.2&view=markup |
13 | plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-analyzer/munin/files/munin-node_init.d_1.4.5-r3?rev=1.2&content-type=text/plain |
14 | diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-analyzer/munin/files/munin-node_init.d_1.4.5-r3?r1=1.1&r2=1.2 |
15 | |
16 | Index: munin-node_init.d_1.4.5-r3 |
17 | =================================================================== |
18 | RCS file: /var/cvsroot/gentoo-x86/net-analyzer/munin/files/munin-node_init.d_1.4.5-r3,v |
19 | retrieving revision 1.1 |
20 | retrieving revision 1.2 |
21 | diff -u -r1.1 -r1.2 |
22 | --- munin-node_init.d_1.4.5-r3 22 Mar 2011 08:37:04 -0000 1.1 |
23 | +++ munin-node_init.d_1.4.5-r3 3 Apr 2011 22:15:50 -0000 1.2 |
24 | @@ -1,7 +1,7 @@ |
25 | #!/sbin/runscript |
26 | # Copyright 1999-2011 Gentoo Foundation |
27 | # Distributed under the terms of the GNU General Public License v2 |
28 | -# $Header: /var/cvsroot/gentoo-x86/net-analyzer/munin/files/munin-node_init.d_1.4.5-r3,v 1.1 2011/03/22 08:37:04 robbat2 Exp $ |
29 | +# $Header: /var/cvsroot/gentoo-x86/net-analyzer/munin/files/munin-node_init.d_1.4.5-r3,v 1.2 2011/04/03 22:15:50 flameeyes Exp $ |
30 | |
31 | [ -z "${NAME}" ] && NAME="munin-node" |
32 | [ -z "${PIDFILE}" ] && PIDFILE=/var/run/munin/$NAME.pid |
33 | @@ -12,6 +12,9 @@ |
34 | } |
35 | |
36 | start() { |
37 | + local piddir=$(dirname ${PIDFILE}) |
38 | + [ -d ${piddir} ] || mkdir -p ${piddir} |
39 | + |
40 | NICE_LEVEL="${NICE_LEVEL:-0}" |
41 | ebegin "Starting $NAME" |
42 | start-stop-daemon --quiet --nicelevel $NICE_LEVEL --start --pidfile $PIDFILE --exec /usr/sbin/$NAME |