]> TLD Linux GIT Repositories - packages/munin.git/blob - munin-separate-configs.patch
- fixed patches
[packages/munin.git] / munin-separate-configs.patch
1 diff -urNpa munin-2.0.42.orig/common/lib/Munin/Common/Defaults.pm munin-2.0.42/common/lib/Munin/Common/Defaults.pm
2 --- munin-2.0.42.orig/common/lib/Munin/Common/Defaults.pm       2018-10-11 15:24:44.276033000 +0000
3 +++ munin-2.0.42/common/lib/Munin/Common/Defaults.pm    2018-10-11 15:25:02.395033000 +0000
4 @@ -18,7 +18,8 @@ my $COMPONENT_ROOT = dirname(__FILE__) .
5  our $DROPDOWNLIMIT     = 1;
6  
7  our $MUNIN_PREFIX     = '';
8 -our $MUNIN_CONFDIR    = "$COMPONENT_ROOT/t/config/";
9 +our $MUNIN_MCONFDIR   = "$COMPONENT_ROOT/t/config/";
10 +our $MUNIN_NCONFDIR   = "$COMPONENT_ROOT/t/config/";
11  our $MUNIN_BINDIR     = '';
12  our $MUNIN_SBINDIR    = '';
13  our $MUNIN_DOCDIR     = '';
14 diff -urNpa munin-2.0.42.orig/doc/installation/configuration.rst munin-2.0.42/doc/installation/configuration.rst
15 --- munin-2.0.42.orig/doc/installation/configuration.rst        2018-10-11 15:24:44.284033000 +0000
16 +++ munin-2.0.42/doc/installation/configuration.rst     2018-10-11 15:25:02.395033000 +0000
17 @@ -9,7 +9,7 @@ Plugins
18  -------
19  
20  Decide which plugins to use. The munin node runs all plugins present
21 -in CONFDIR/plugins/
22 +in NCONFDIR/plugins/
23  
24  The quick auto-plug-and-play solution:
25  
26 @@ -59,7 +59,7 @@ Master
27  Add some nodes
28  --------------
29  
30 -Add some nodes to CONFDIR/munin.conf
31 +Add some nodes to MCONFDIR/munin.conf
32  
33  [node.example.com]
34    address 192.0.2.4
35 diff -urNpa munin-2.0.42.orig/Makefile munin-2.0.42/Makefile
36 --- munin-2.0.42.orig/Makefile  2018-10-11 15:24:44.275033000 +0000
37 +++ munin-2.0.42/Makefile       2018-10-11 16:29:37.518033000 +0000
38 @@ -81,7 +81,7 @@ uninstall:
39  # a new config.  Target _only_ suitable for maintainers.
40  unconfig:
41         rm -f $(HTMLDIR)/.htaccess
42 -       rm -f $(CONFDIR)/munin.conf
43 +       rm -f $(MCONFDIR)/munin.conf
44  
45  tags:
46         -rm -f TAGS
47 @@ -96,14 +96,15 @@ install-pre: Makefile Makefile.config
48         mkdir -p $(LOGDIR)
49         mkdir -p $(STATEDIR)
50         mkdir -p $(SPOOLDIR)
51 -       mkdir -p $(CONFDIR)
52 +       mkdir -p $(NCONFDIR)
53 +       mkdir -p $(MCONFDIR)
54         $(CHOWN) $(USER) $(LOGDIR) $(STATEDIR) $(SPOOLDIR)
55  
56  install-master-prime: $(INFILES_MASTER) install-pre install-master
57         mkdir -p $(TEMPLATEDIR)
58         mkdir -p $(TEMPLATEDIR)/static
59         mkdir -p $(TEMPLATEDIR)/partial
60 -       mkdir -p $(CONFDIR)/munin-conf.d
61 +       mkdir -p $(MCONFDIR)/munin-conf.d
62         mkdir -p $(LIBDIR)
63         mkdir -p $(BINDIR)
64         mkdir -p $(SBINDIR)
65 @@ -136,7 +137,7 @@ install-master-prime: $(INFILES_MASTER)
66         $(INSTALL) -m 0644 master/DejaVuSans.ttf $(LIBDIR)/
67  
68         test -f $(HTMLDIR)/.htaccess || $(INSTALL) -m 0644 build/master/www/munin-htaccess $(HTMLDIR)/.htaccess
69 -       test -f "$(CONFDIR)/munin.conf"  || $(INSTALL) -m 0644 build/master/munin.conf $(CONFDIR)/
70 +       test -f "$(MCONFDIR)/munin.conf"  || $(INSTALL) -m 0644 build/master/munin.conf $(MCONFDIR)/
71  
72         $(INSTALL) -m 0755 build/master/_bin/munin-cron $(SBINDIR)/
73         $(INSTALL) -m 0755 build/master/_bin/munin-check $(LIBDIR)/
74 @@ -157,14 +158,14 @@ install-node-plugins: install-plugins-pr
75  install-plugins-prime: install-plugins build $(PLUGINS) Makefile Makefile.config
76         @$(CHECKGROUP)
77  
78 -       mkdir -p $(CONFDIR)/plugins
79 -       mkdir -p $(CONFDIR)/plugin-conf.d
80 +       mkdir -p $(NCONFDIR)/plugins
81 +       mkdir -p $(NCONFDIR)/plugin-conf.d
82         mkdir -p $(LIBDIR)/plugins
83         mkdir -p $(PLUGSTATE)
84  
85         $(CHOWN) root:root $(PLUGSTATE)
86         $(CHMOD) 0755 $(PLUGSTATE)
87 -       $(CHMOD) 0755 $(CONFDIR)/plugin-conf.d
88 +       $(CHMOD) 0755 $(NCONFDIR)/plugin-conf.d
89  
90         @# Process the OS specific plugins at the end. Otherwise they would be overridden by the
91         @# generic ones.
92 @@ -204,7 +205,7 @@ install-async:
93  install-node-prime: install-node-pre install-node
94  
95  install-node-pre: build/node/munin-node.conf install-pre
96 -       test -f "$(CONFDIR)/munin-node.conf" || $(INSTALL) -m 0644 build/node/munin-node.conf $(CONFDIR)/
97 +       test -f "$(NCONFDIR)/munin-node.conf" || $(INSTALL) -m 0644 build/node/munin-node.conf $(NCONFDIR)/
98  
99  
100  install-common-prime: build-common install-common
101 @@ -240,7 +241,8 @@ build/%: %.in
102         @echo "$< -> $@"
103         @mkdir -p build/`dirname $<`
104         @sed -e 's|@@PREFIX@@|$(PREFIX)|g' \
105 -               -e 's|@@CONFDIR@@|$(CONFDIR)|g' \
106 +               -e 's|@@MCONFDIR@@|$(MCONFDIR)|g' \
107 +               -e 's|@@NCONFDIR@@|$(NCONFDIR)|g' \
108                 -e 's|@@BINDIR@@|$(BINDIR)|g' \
109                 -e 's|@@SBINDIR@@|$(SBINDIR)|g' \
110                 -e 's|@@DOCDIR@@|$(DOCDIR)|g' \
111 @@ -283,7 +285,8 @@ $(CONFVAR_SUBSTITUTION_DEP_FILES): build
112  
113  substitute-confvar-inline:
114         perl -p -i -e 's|\@\@PREFIX\@\@|$(PREFIX)|g;' \
115 -               -e 's|\@\@CONFDIR\@\@|$(CONFDIR)|g;' \
116 +               -e 's|\@\@MCONFDIR\@\@|$(MCONFDIR)|g;' \
117 +               -e 's|\@\@NCONFDIR\@\@|$(NCONFDIR)|g;' \
118                 -e 's|\@\@BINDIR\@\@|$(BINDIR)|g;' \
119                 -e 's|\@\@SBINDIR\@\@|$(SBINDIR)|g;' \
120                 -e 's|\@\@DOCDIR\@\@|$(DOCDIR)|g;' \
121 @@ -339,7 +342,8 @@ common/blib/lib/Munin/Common/Defaults.pm
122  substitute-build-defaults-inline:
123         rm -f common/blib/lib/Munin/Common/Defaults.pm
124         $(PERL) -pe 's{(PREFIX\s+=\s).*}{\1q{$(PREFIX)};}x; \
125 -               s{(CONFDIR\s+=\s).*}{\1q{$(CONFDIR)};}x; \
126 +               s{(MCONFDIR\s+=\s).*}{\1q{$(MCONFDIR)};}x; \
127 +               s{(NCONFDIR\s+=\s).*}{\1q{$(NCONFDIR)};}x; \
128                 s{(BINDIR\s+=\s).*}{\1q{$(BINDIR)};}x; \
129                 s{(SBINDIR\s+=\s).*}{\1q{$(SBINDIR)};}x; \
130                 s{(DOCDIR\s+=\s).*}{\1q{$(DOCDIR)};}x; \
131 @@ -493,7 +497,7 @@ old-test: t/*.t
132         $(MAKE) $@ CONFIG=t/Makefile.config
133  else
134  test_plugins = id_default id_root env
135 -old-test: t/*.t t/install $(addprefix $(CONFDIR)/plugins/,$(test_plugins))
136 +old-test: t/*.t t/install $(addprefix $(NCONFDIR)/plugins/,$(test_plugins))
137         @for test in t/*.t; do \
138                 echo -n "$$test: "; \
139                 PERL5LIB=$(PERLLIB) $(PERL) $$test;\
140 @@ -501,10 +505,10 @@ old-test: t/*.t t/install $(addprefix $(
141  endif
142  
143  node-monkeywrench: install-node
144 -       rm -rf $(CONFDIR)/plugins
145 +       rm -rf $(NCONFDIR)/plugins
146         rm -rf $(LIBDIR)/plugins
147         mkdir -p $(LIBDIR)/plugins
148 -       mkdir -p $(CONFDIR)/plugins
149 +       mkdir -p $(NCONFDIR)/plugins
150         cp monkeywrench/plugin-break*_ $(LIBDIR)/plugins/
151         $(SBINDIR)/munin-node-configure --suggest
152         echo 'Done?'
153 diff -urNpa munin-2.0.42.orig/Makefile.config munin-2.0.42/Makefile.config
154 --- munin-2.0.42.orig/Makefile.config   2018-10-11 15:24:44.282033000 +0000
155 +++ munin-2.0.42/Makefile.config        2018-10-11 15:25:02.396033000 +0000
156 @@ -20,7 +20,8 @@
157  PREFIX     = $(DESTDIR)/usr
158  
159  # Where Munin keeps its configurations (server.conf, client.conf, ++)
160 -CONFDIR    = $(DESTDIR)/etc/munin
161 +NCONFDIR    = $(DESTDIR)/etc/munin
162 +MCONFDIR    = $(DESTDIR)/etc/webapps/munin
163  
164  # Server only - where to put munin-cron
165  BINDIR     = $(PREFIX)/bin
166 diff -urNpa munin-2.0.42.orig/master/_bin/munin-cgi-graph.in munin-2.0.42/master/_bin/munin-cgi-graph.in
167 --- munin-2.0.42.orig/master/_bin/munin-cgi-graph.in    2018-10-11 15:24:44.285033000 +0000
168 +++ munin-2.0.42/master/_bin/munin-cgi-graph.in 2018-10-11 15:25:02.396033000 +0000
169 @@ -44,7 +44,7 @@ use Munin::Master::Logger;
170  use Log::Log4perl qw( :easy );
171  
172  my $GRAPHER = "$Munin::Common::Defaults::MUNIN_LIBDIR/munin-graph";
173 -my $conffile = "$Munin::Common::Defaults::MUNIN_CONFDIR/munin.conf";
174 +my $conffile = "$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.conf";
175  
176  my %period  = ( "day"   => 300,
177                 "week"  => 1800,
178 diff -urNpa munin-2.0.42.orig/master/_bin/munin-check.in munin-2.0.42/master/_bin/munin-check.in
179 --- munin-2.0.42.orig/master/_bin/munin-check.in        2018-10-11 15:24:44.285033000 +0000
180 +++ munin-2.0.42/master/_bin/munin-check.in     2018-10-11 15:25:02.396033000 +0000
181 @@ -163,7 +163,7 @@ done
182  norec=yes owner_ok @@PLUGSTATE@@ @@PLUGINUSER@@
183  norec=yes perm_ok @@PLUGSTATE@@ 775
184  
185 -norec=yes perm_ok @@CONFDIR@@/plugin-conf.d 755
186 +norec=yes perm_ok @@NCONFDIR@@/plugin-conf.d 755
187  
188  echo "Check done.  Please note that this script only checks most things,"
189  echo "not all things."
190 diff -urNpa munin-2.0.42.orig/master/_bin/munin-graph.in munin-2.0.42/master/_bin/munin-graph.in
191 --- munin-2.0.42.orig/master/_bin/munin-graph.in        2018-10-11 15:24:44.285033000 +0000
192 +++ munin-2.0.42/master/_bin/munin-graph.in     2018-10-11 15:25:02.396033000 +0000
193 @@ -51,7 +51,7 @@ use Munin::Master::Logger;
194  use Log::Log4perl qw( :easy );
195  
196  my $GRAPHER = "$Munin::Common::Defaults::MUNIN_LIBDIR/munin-graph";
197 -my $conffile = "$Munin::Common::Defaults::MUNIN_CONFDIR/munin.conf";
198 +my $conffile = "$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.conf";
199  
200  my %period  = ( "day"   => 300,
201                 "week"  => 1800,
202 diff -urNpa munin-2.0.42.orig/master/_bin/munin-limits.in munin-2.0.42/master/_bin/munin-limits.in
203 --- munin-2.0.42.orig/master/_bin/munin-limits.in       2018-10-11 15:24:44.285033000 +0000
204 +++ munin-2.0.42/master/_bin/munin-limits.in    2018-10-11 15:25:02.396033000 +0000
205 @@ -66,7 +66,7 @@ Limit contacts to those of E<lt>contact<
206  
207  =item B<< --config <file> >>
208  
209 -Use E<lt>fileE<gt> as configuration file. [@@CONFDIR@@/munin.conf]
210 +Use E<lt>fileE<gt> as configuration file. [@@MCONFDIR@@/munin.conf]
211  
212  =item B<< --always-send <severity list> >>
213  
214 @@ -114,7 +114,7 @@ configuration file contains the necessar
215  
216  =head1 FILES
217  
218 -       @@CONFDIR@@/munin.conf
219 +       @@MCONFDIR@@/munin.conf
220         @@DBDIR@@/*
221         @@STATEDIR@@/*
222  
223 diff -urNpa munin-2.0.42.orig/master/_bin/munin-update.in munin-2.0.42/master/_bin/munin-update.in
224 --- munin-2.0.42.orig/master/_bin/munin-update.in       2018-10-11 15:24:44.285033000 +0000
225 +++ munin-2.0.42/master/_bin/munin-update.in    2018-10-11 15:25:02.396033000 +0000
226 @@ -139,7 +139,7 @@ munin-update [options]
227  
228  =item B<< --config_file=<file> >>
229  
230 -Use E<lt>fileE<gt> as the configuration file. [@@CONFDIR@@/munin.conf]
231 +Use E<lt>fileE<gt> as the configuration file. [@@MCONFDIR@@/munin.conf]
232  
233  =item B<< --[no]debug >>
234  
235 @@ -192,7 +192,7 @@ and the directories to store them in.
236  
237  =head1 FILES
238  
239 -       @@CONFDIR@@/munin.conf
240 +       @@MCONFDIR@@/munin.conf
241         @@DBDIR@@/*
242         @@LOGDIR@@/munin-update
243         @@STATEDIR@@/*
244 diff -urNpa munin-2.0.42.orig/master/doc/munin.conf.pod.in munin-2.0.42/master/doc/munin.conf.pod.in
245 --- munin-2.0.42.orig/master/doc/munin.conf.pod.in      2018-10-11 15:24:44.285033000 +0000
246 +++ munin-2.0.42/master/doc/munin.conf.pod.in   2018-10-11 15:25:02.396033000 +0000
247 @@ -27,7 +27,7 @@ something like:
248         [machine1.your.dom]
249                 address localhost
250  
251 -The default location of F<munin.conf> is F<@@CONFDIR@@/munin.conf>.
252 +The default location of F<munin.conf> is F<@@MCONFDIR@@/munin.conf>.
253  If your placement deviates from this norm, use the "--config
254  E<lt>fileE<gt>"-option when running the munin-* programs.
255  
256 @@ -162,20 +162,20 @@ is C<no>.  Affects: munin-update.
257  =item B<tls_private_key> <value>
258  
259  This directive sets the location of the private key to be used for
260 -TLS.  Default is @@CONFDIR@@/munin.pem.  The private key and
261 +TLS.  Default is @@MCONFDIR@@/munin.pem.  The private key and
262  certificate can be stored in the same file.  Affects: munin-update.
263  
264  =item B<tls_certificate> <value>
265  
266  This directive sets the location of the TLS certificate to be used for
267 -TLS.  Default is @@CONFDIR@@/munin.pem.  The private key and
268 +TLS.  Default is @@MCONFDIR@@/munin.pem.  The private key and
269  certificate can be stored in the same file.  Affects: munin-update.
270  
271  =item B<tls_ca_certificate> <value>
272  
273  This directive sets the CA certificate to be used to verify the node's
274  certificate, if tls_verify_certificate is set to C<yes>.  Default is
275 -@@CONFDIR@@/cacert.pem.  Affects: munin-update.
276 +@@MCONFDIR@@/cacert.pem.  Affects: munin-update.
277  
278  =item B<tls_verify_depth> <value>
279  
280 diff -urNpa munin-2.0.42.orig/master/doc/munin-cron.pod.in munin-2.0.42/master/doc/munin-cron.pod.in
281 --- munin-2.0.42.orig/master/doc/munin-cron.pod.in      2018-10-11 15:24:44.285033000 +0000
282 +++ munin-2.0.42/master/doc/munin-cron.pod.in   2018-10-11 15:25:02.396033000 +0000
283 @@ -22,7 +22,7 @@ Limit hosts to E<lt>hostE<gt>. Multiple
284  
285  =item B<< --config <file> >>
286  
287 -Use E<lt>fileE<gt> as configuration file. [F<@@CONFDIR@@/munin.conf>]
288 +Use E<lt>fileE<gt> as configuration file. [F<@@MCONFDIR@@/munin.conf>]
289  
290  =back
291  
292 diff -urNpa munin-2.0.42.orig/master/extras/munin-update_old.in munin-2.0.42/master/extras/munin-update_old.in
293 --- munin-2.0.42.orig/master/extras/munin-update_old.in 2018-10-11 15:24:44.285033000 +0000
294 +++ munin-2.0.42/master/extras/munin-update_old.in      2018-10-11 15:25:02.396033000 +0000
295 @@ -43,7 +43,7 @@ my $DEBUG=0;
296  my $STATS;
297  my $cli_do_fork;
298  my $cli_timeout;
299 -my $conffile = "$Munin::Common::Defaults::MUNIN_CONFDIR/munin.conf";
300 +my $conffile = "$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.conf";
301  my $config;
302  my $do_fork = 1;
303  my $serversocket  = "munin-server-socket.$$";
304 @@ -159,7 +159,7 @@ Options:
305      --host <host>      Limit graphed hosts to <host>. Multiple --host options
306                         may be supplied.
307      --config <file>    Use <file> as configuration file. 
308 -                       [$Munin::Common::Defaults::MUNIN_CONFDIR/munin.conf]
309 +                       [$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.conf]
310      --[no]debug                View debug messages. [--nodebug]
311      --[no]fork         Don't fork one instance for each host. [--fork]
312      --timeout=<seconds>        TCP timeout when talking to clients. [$timeout]
313 @@ -752,11 +752,11 @@ sub run_starttls_if_required {
314         my $ca_cert;
315         my $tls_verify;
316          $key = $cert = munin_get ($config, "tls_pem");
317 -        $key = &munin_get ($config, "tls_private_key", "$Munin::Common::Defaults::MUNIN_CONFDIR/munin.pem")
318 +        $key = &munin_get ($config, "tls_private_key", "$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.pem")
319           unless defined $key;
320 -        $cert = &munin_get ($config, "tls_certificate", "$Munin::Common::Defaults::MUNIN_CONFDIR/munin.pem")
321 +        $cert = &munin_get ($config, "tls_certificate", "$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.pem")
322           unless defined $cert;
323 -        $ca_cert = &munin_get ($config, "tls_ca_certificate", "$Munin::Common::Defaults::MUNIN_CONFDIR/cacert.pem")
324 +        $ca_cert = &munin_get ($config, "tls_ca_certificate", "$Munin::Common::Defaults::MUNIN_MCONFDIR/cacert.pem")
325             unless defined $ca_cert;
326          $tls_verify=&munin_get ($config, "tls_verify_certificate", "no");
327          $depth=&munin_get ($config, "tls_verify_depth", 5);
328 @@ -1088,7 +1088,7 @@ Limit fetched data to those from E<lt>ho
329  
330  =item B<< --config <file> >>
331  
332 -Use E<lt>fileE<gt> as configuration file. [@@CONFDIR@@/munin.conf]
333 +Use E<lt>fileE<gt> as configuration file. [@@MCONFDIR@@/munin.conf]
334  
335  =item B<< --help >>
336  
337 @@ -1124,7 +1124,7 @@ and the directories to store them in.
338  
339  =head1 FILES
340  
341 -       @@CONFDIR@@/munin.conf
342 +       @@MCONFDIR@@/munin.conf
343         @@DBDIR@@/*
344         @@LOGDIR@@/munin-update
345         @@STATEDIR@@/*
346 diff -urNpa munin-2.0.42.orig/master/lib/Munin/Master/Config.pm munin-2.0.42/master/lib/Munin/Master/Config.pm
347 --- munin-2.0.42.orig/master/lib/Munin/Master/Config.pm 2018-10-11 15:24:44.285033000 +0000
348 +++ munin-2.0.42/master/lib/Munin/Master/Config.pm      2018-10-11 15:25:02.397033000 +0000
349 @@ -140,7 +140,7 @@ my %booleans = map {$_ => 1} qw(
350             root_instance => 1, 
351  
352             config      => bless ( {
353 -               config_file      => "$Munin::Common::Defaults::MUNIN_CONFDIR/munin.conf",
354 +               config_file      => "$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.conf",
355                 dbdir            => $Munin::Common::Defaults::MUNIN_DBDIR,
356                 debug            => 0,
357                 fork             => 1,
358 @@ -154,9 +154,9 @@ my %booleans = map {$_ => 1} qw(
359                 rundir           => $Munin::Common::Defaults::MUNIN_STATEDIR,
360                 timeout          => 180,
361                 tls              => 'disabled',
362 -               tls_ca_certificate => "$Munin::Common::Defaults::MUNIN_CONFDIR/cacert.pem",
363 -               tls_certificate  => "$Munin::Common::Defaults::MUNIN_CONFDIR/munin.pem",
364 -               tls_private_key  => "$Munin::Common::Defaults::MUNIN_CONFDIR/munin.pem",
365 +               tls_ca_certificate => "$Munin::Common::Defaults::MUNIN_MCONFDIR/cacert.pem",
366 +               tls_certificate  => "$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.pem",
367 +               tls_private_key  => "$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.pem",
368                 tls_verify_certificate => 0,
369                 tls_verify_depth => 5,
370                 tmpldir          => "$Munin::Common::Defaults::MUNIN_TEMPLATEDIR",
371 diff -urNpa munin-2.0.42.orig/master/lib/Munin/Master/GraphOld.pm munin-2.0.42/master/lib/Munin/Master/GraphOld.pm
372 --- munin-2.0.42.orig/master/lib/Munin/Master/GraphOld.pm       2018-10-11 15:24:44.285033000 +0000
373 +++ munin-2.0.42/master/lib/Munin/Master/GraphOld.pm    2018-10-11 15:25:02.397033000 +0000
374 @@ -97,7 +97,7 @@ my $skip_locking   = 0;
375  my $skip_stats     = 0;
376  my $stdout         = 0;
377  my $force_run_as_root = 0;
378 -my $conffile       = $Munin::Common::Defaults::MUNIN_CONFDIR . "/munin.conf";
379 +my $conffile       = $Munin::Common::Defaults::MUNIN_MCONFDIR . "/munin.conf";
380  my $libdir         = $Munin::Common::Defaults::MUNIN_LIBDIR;
381  # Note: Nothing by default is more convenient and elliminates code while
382  # for cgi graphing - but it breaks how munin-graph expected stuff to work.
383 diff -urNpa munin-2.0.42.orig/master/lib/Munin/Master/HTMLOld.pm munin-2.0.42/master/lib/Munin/Master/HTMLOld.pm
384 --- munin-2.0.42.orig/master/lib/Munin/Master/HTMLOld.pm        2018-10-11 15:24:44.285033000 +0000
385 +++ munin-2.0.42/master/lib/Munin/Master/HTMLOld.pm     2018-10-11 15:25:02.397033000 +0000
386 @@ -83,7 +83,7 @@ use Log::Log4perl qw( :easy );
387  my @times = ("day", "week", "month", "year");
388  
389  my $DEBUG      = 0;
390 -my $conffile   = "$Munin::Common::Defaults::MUNIN_CONFDIR/munin.conf";
391 +my $conffile   = "$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.conf";
392  my $do_usage   = 0;
393  my $do_version = 0;
394  my $stdout     = 0;
395 @@ -859,7 +859,7 @@ Options:
396      --service <service>        Compatibility. No effect.
397      --host <host>      Compatibility. No effect.
398      --config <file>    Use <file> as configuration file. 
399 -                       [/etc/munin/munin.conf]
400 +                       [$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.conf]
401  
402  ";
403      exit 0;
404 @@ -894,7 +894,7 @@ Compatibility. No effect.
405  
406  =item B<< --config <file> >>
407  
408 -Use E<lt>fileE<gt> as configuration file. [/etc/munin/munin.conf]
409 +Use E<lt>fileE<gt> as configuration file. [@@MCONFDIR@@/munin.conf]
410  
411  =item B<< --help >>
412  
413 @@ -917,7 +917,7 @@ Munin-html creates the html pages.
414  
415  =head1 FILES
416  
417 -       @@CONFDIR@@/munin.conf
418 +       @@MCONFDIR@@/munin.conf
419         @@DBDIR@@/datafile
420         @@LOGDIR@@/munin-html
421         @@HTMLDIR@@/*
422 diff -urNpa munin-2.0.42.orig/master/lib/Munin/Master/LimitsOld.pm munin-2.0.42/master/lib/Munin/Master/LimitsOld.pm
423 --- munin-2.0.42.orig/master/lib/Munin/Master/LimitsOld.pm      2018-10-11 15:24:44.285033000 +0000
424 +++ munin-2.0.42/master/lib/Munin/Master/LimitsOld.pm   2018-10-11 15:25:02.397033000 +0000
425 @@ -52,7 +52,7 @@ use Munin::Master::Utils;
426  use Munin::Common::Defaults;
427  
428  my $DEBUG          = 0;
429 -my $conffile       = "$Munin::Common::Defaults::MUNIN_CONFDIR/munin.conf";
430 +my $conffile       = "$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.conf";
431  my $do_usage       = 0;
432  my $do_version     = 0;
433  my @limit_hosts    = ();
434 @@ -242,7 +242,7 @@ Options:
435      --contact <contact>        Limit notified contacts to <contact>. Multiple 
436                         --contact options may be supplied.
437      --config <file>    Use <file> as configuration file. 
438 -                       [/etc/munin/munin.conf]
439 +                       [$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.conf]
440  
441  ";
442      exit 0;
443 diff -urNpa munin-2.0.42.orig/master/lib/Munin/Master/Utils.pm munin-2.0.42/master/lib/Munin/Master/Utils.pm
444 --- munin-2.0.42.orig/master/lib/Munin/Master/Utils.pm  2018-10-11 15:24:44.285033000 +0000
445 +++ munin-2.0.42/master/lib/Munin/Master/Utils.pm       2018-10-11 15:25:02.397033000 +0000
446 @@ -114,7 +114,7 @@ my $config_parts = {
447         },
448  };
449  
450 -my $configfile="$Munin::Common::Defaults::MUNIN_CONFDIR/munin.conf";
451 +my $configfile="$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.conf";
452  
453  # Fields to copy when "aliasing" a field
454  my @COPY_FIELDS    = ("label", "draw", "type", "rrdfile", "fieldname", "info");
455 diff -urNpa munin-2.0.42.orig/master/munin.conf.in munin-2.0.42/master/munin.conf.in
456 --- munin-2.0.42.orig/master/munin.conf.in      2018-10-11 15:24:44.286033000 +0000
457 +++ munin-2.0.42/master/munin.conf.in   2018-10-11 15:25:02.397033000 +0000
458 @@ -24,7 +24,7 @@
459  # cgitmpdir @@DBDIR@@/cgi-tmp
460  
461  # (Exactly one) directory to include all files from.
462 -includedir @@CONFDIR@@/munin-conf.d
463 +includedir @@MCONFDIR@@/munin-conf.d
464  
465  # You can choose the time reference for "DERIVE" like graphs, and show
466  # "per minute", "per hour" values instead of the default "per second"
467 diff -urNpa munin-2.0.42.orig/master/t/munin_master_config.t munin-2.0.42/master/t/munin_master_config.t
468 --- munin-2.0.42.orig/master/t/munin_master_config.t    2018-10-11 15:24:44.285033000 +0000
469 +++ munin-2.0.42/master/t/munin_master_config.t 2018-10-11 15:25:02.398033000 +0000
470 @@ -24,7 +24,7 @@ my $fasit = {
471      },
472  
473      config => {
474 -        config_file     => "$Munin::Common::Defaults::MUNIN_CONFDIR/munin.conf",
475 +        config_file     => "$Munin::Common::Defaults::MUNIN_MCONFDIR/munin.conf",
476          dbdir           => '/opt/munin/sandbox/var/opt/munin',
477          debug           => 0,
478          fork            => 1,
479 diff -urNpa munin-2.0.42.orig/master/www/munin-htaccess.in munin-2.0.42/master/www/munin-htaccess.in
480 --- munin-2.0.42.orig/master/www/munin-htaccess.in      2018-10-11 15:24:44.286033000 +0000
481 +++ munin-2.0.42/master/www/munin-htaccess.in   2018-10-11 15:25:02.398033000 +0000
482 @@ -9,7 +9,7 @@
483  # 
484  # <directory @@HTMLDIR@@>
485  
486 -AuthUserFile @@CONFDIR@@/munin-htpasswd
487 +AuthUserFile @@MCONFDIR@@/munin-htpasswd
488  AuthName "Munin"
489  AuthType Basic
490  require valid-user
491 diff -urNpa munin-2.0.42.orig/node/bin/munindoc munin-2.0.42/node/bin/munindoc
492 --- munin-2.0.42.orig/node/bin/munindoc 2018-10-11 15:24:44.286033000 +0000
493 +++ munin-2.0.42/node/bin/munindoc      2018-10-11 15:25:02.398033000 +0000
494 @@ -48,7 +48,7 @@ my $plugin_re = quotemeta($plugin);
495  
496  # Dirs in which to look for $plugin.pod and $plugin files.
497  my @DIRS = ("$Munin::Common::Defaults::MUNIN_LIBDIR/plugins",
498 -           "$Munin::Common::Defaults::MUNIN_CONFDIR/plugins",
499 +           "$Munin::Common::Defaults::MUNIN_NCONFDIR/plugins",
500              "$Munin::Common::Defaults::MUNIN_PERLLIB");
501  
502  File::Find::find({wanted => \&wanted_pod}, @DIRS);
503 diff -urNpa munin-2.0.42.orig/node/doc/munin-node.conf.pod munin-2.0.42/node/doc/munin-node.conf.pod
504 --- munin-2.0.42.orig/node/doc/munin-node.conf.pod      2018-10-11 15:24:44.286033000 +0000
505 +++ munin-2.0.42/node/doc/munin-node.conf.pod   2018-10-11 15:25:02.398033000 +0000
506 @@ -91,20 +91,20 @@ is C<no>.
507  =item B<tls_private_key> <value>
508  
509  This directive sets the location of the private key to be used for
510 -TLS.  Default is @@CONFDIR@@/munin-node.pem.  The private key and
511 +TLS.  Default is @@NCONFDIR@@/munin-node.pem.  The private key and
512  certificate can be stored in the same file.
513  
514  =item B<tls_certificate> <value>
515  
516  This directive sets the location of the TLS certificate to be used for
517 -TLS.  Default is @@CONFDIR@@/munin-node.pem.  The private key and
518 +TLS.  Default is @@NCONFDIR@@/munin-node.pem.  The private key and
519  certificate can be stored in the same file.
520  
521  =item B<tls_ca_certificate> <value>
522  
523  This directive sets the CA certificate to be used to verify the node's
524  certificate, if tls_verify_certificate is set to C<yes>.  Default is
525 -@@CONFDIR@@/cacert.pem.
526 +@@NCONFDIR@@/cacert.pem.
527  
528  =item B<tls_verify_depth> <value>
529  
530 diff -urNpa munin-2.0.42.orig/node/extras/munin-node-simple.in munin-2.0.42/node/extras/munin-node-simple.in
531 --- munin-2.0.42.orig/node/extras/munin-node-simple.in  2018-10-11 15:24:44.286033000 +0000
532 +++ munin-2.0.42/node/extras/munin-node-simple.in       2018-10-11 15:25:02.398033000 +0000
533 @@ -28,8 +28,8 @@ use strict;
534  
535  $| = 1;
536  
537 -my $clientdir = "@@CONFDIR@@/node.d";
538 -my $conffile  = "@@CONFDIR@@/node-simple.conf";
539 +my $clientdir = "@@NCONFDIR@@/node.d";
540 +my $conffile  = "@@NCONFDIR@@/node-simple.conf";
541  my $version   = "@@VERSION@@";
542  
543  # Empty environment
544 diff -urNpa munin-2.0.42.orig/node/lib/Munin/Node/Config.pm munin-2.0.42/node/lib/Munin/Node/Config.pm
545 --- munin-2.0.42.orig/node/lib/Munin/Node/Config.pm     2018-10-11 15:24:44.286033000 +0000
546 +++ munin-2.0.42/node/lib/Munin/Node/Config.pm  2018-10-11 15:25:02.398033000 +0000
547 @@ -25,7 +25,7 @@ my %booleans = map {$_ => 1} qw(
548          my ($class) = @_;
549  
550          $instance ||= bless {
551 -            config_file  => "$Munin::Common::Defaults::MUNIN_CONFDIR/munin-node.conf",
552 +            config_file  => "$Munin::Common::Defaults::MUNIN_NCONFDIR/munin-node.conf",
553          }, $class;
554  
555          return $instance;
556 diff -urNpa munin-2.0.42.orig/node/lib/Munin/Node/Server.pm munin-2.0.42/node/lib/Munin/Node/Server.pm
557 --- munin-2.0.42.orig/node/lib/Munin/Node/Server.pm     2018-10-11 15:24:44.286033000 +0000
558 +++ munin-2.0.42/node/lib/Munin/Node/Server.pm  2018-10-11 15:25:02.398033000 +0000
559 @@ -272,11 +272,11 @@ sub _process_starttls_command {
560      my $mode = $session->{tls_mode};
561  
562      my $key        = $config->{tls_private_key}
563 -                  || "$Munin::Common::Defaults::MUNIN_CONFDIR/munin-node.pem";
564 +                  || "$Munin::Common::Defaults::MUNIN_NCONFDIR/munin-node.pem";
565      my $cert       = $config->{tls_certificate}
566 -                  || "$Munin::Common::Defaults::MUNIN_CONFDIR/munin-node.pem";
567 +                  || "$Munin::Common::Defaults::MUNIN_NCONFDIR/munin-node.pem";
568      my $ca_cert    = $config->{tls_ca_certificate}
569 -                  || "$Munin::Common::Defaults::MUNIN_CONFDIR/cacert.pem";
570 +                  || "$Munin::Common::Defaults::MUNIN_NCONFDIR/cacert.pem";
571      my $tls_verify = $config->{tls_verify_certificate}
572                    || 0;
573      my $tls_match  = $config->{tls_match};
574 diff -urNpa munin-2.0.42.orig/node/lib/Munin/Node/Service.pm munin-2.0.42/node/lib/Munin/Node/Service.pm
575 --- munin-2.0.42.orig/node/lib/Munin/Node/Service.pm    2018-10-11 15:24:44.286033000 +0000
576 +++ munin-2.0.42/node/lib/Munin/Node/Service.pm 2018-10-11 15:25:02.398033000 +0000
577 @@ -22,7 +22,7 @@ sub new
578      my ($class, %args) = @_;
579  
580      # Set defaults
581 -    $args{servicedir} ||= "$Munin::Common::Defaults::MUNIN_CONFDIR/plugins";
582 +    $args{servicedir} ||= "$Munin::Common::Defaults::MUNIN_NCONFDIR/plugins";
583  
584      $args{defuser}  ||= getpwnam $Munin::Common::Defaults::MUNIN_PLUGINUSER;
585      $args{defgroup} ||= getgrnam $Munin::Common::Defaults::MUNIN_GROUP;
586 diff -urNpa munin-2.0.42.orig/node/sbin/munin-node munin-2.0.42/node/sbin/munin-node
587 --- munin-2.0.42.orig/node/sbin/munin-node      2018-10-11 15:24:44.286033000 +0000
588 +++ munin-2.0.42/node/sbin/munin-node   2018-10-11 15:25:02.398033000 +0000
589 @@ -36,8 +36,8 @@ use Munin::Node::Service;
590  use Munin::Node::Server;
591  
592  my $servicedir;
593 -my $sconfdir = "$Munin::Common::Defaults::MUNIN_CONFDIR/plugin-conf.d";
594 -my $conffile = "$Munin::Common::Defaults::MUNIN_CONFDIR/munin-node.conf";
595 +my $sconfdir = "$Munin::Common::Defaults::MUNIN_NCONFDIR/plugin-conf.d";
596 +my $conffile = "$Munin::Common::Defaults::MUNIN_NCONFDIR/munin-node.conf";
597  my $DEBUG    = 0;
598  my $PIDEBUG  = 0;
599  my $paranoia = 0;
600 @@ -164,7 +164,7 @@ and returning the output they produce.
601  
602  =item B<< --config <configfile> >>
603  
604 -Use E<lt>fileE<gt> as configuration file. [@@CONFDIR@@/munin-node.conf]
605 +Use E<lt>fileE<gt> as configuration file. [@@NCONFDIR@@/munin-node.conf]
606  
607  =item B< --[no]paranoia >
608  
609 @@ -187,9 +187,9 @@ may enable debugging. [--nopidebug]
610  
611  =head1 FILES
612  
613 -    @@CONFDIR@@/munin-node.conf
614 -    @@CONFDIR@@/plugins/*
615 -    @@CONFDIR@@/plugin-conf.d/*
616 +    @@NCONFDIR@@/munin-node.conf
617 +    @@NCONFDIR@@/plugins/*
618 +    @@NCONFDIR@@/plugin-conf.d/*
619      @@STATEDIR@@/munin-node.pid
620      @@LOGDIR@@/munin-node.log
621  
622 diff -urNpa munin-2.0.42.orig/node/sbin/munin-node-configure munin-2.0.42/node/sbin/munin-node-configure
623 --- munin-2.0.42.orig/node/sbin/munin-node-configure    2018-10-11 15:24:44.286033000 +0000
624 +++ munin-2.0.42/node/sbin/munin-node-configure 2018-10-11 15:25:02.399033000 +0000
625 @@ -76,9 +76,9 @@ sub main
626  
627  sub parse_args
628  {
629 -       my $conffile   = "$Munin::Common::Defaults::MUNIN_CONFDIR/munin-node.conf";
630 -       my $servicedir = "$Munin::Common::Defaults::MUNIN_CONFDIR/plugins";
631 -       my $sconfdir   = "$Munin::Common::Defaults::MUNIN_CONFDIR/plugin-conf.d";
632 +       my $conffile   = "$Munin::Common::Defaults::MUNIN_NCONFDIR/munin-node.conf";
633 +       my $servicedir = "$Munin::Common::Defaults::MUNIN_NCONFDIR/plugins";
634 +       my $sconfdir   = "$Munin::Common::Defaults::MUNIN_NCONFDIR/plugin-conf.d";
635         my $libdir     = "$Munin::Common::Defaults::MUNIN_LIBDIR/plugins";
636  
637         my $debug = 0;
638 @@ -487,15 +487,15 @@ may enable debugging.
639  
640  =item B<< --config <file> >>
641  
642 -Override configuration file [@@CONFDIR@@/munin-node.conf]
643 +Override configuration file [@@NCONFDIR@@/munin-node.conf]
644  
645  =item B<< --servicedir <dir> >>
646  
647 -Override plugin directory [@@CONFDIR@@/plugins/]
648 +Override plugin directory [@@NCONFDIR@@/plugins/]
649  
650  =item B<< --sconfdir <dir> >>
651  
652 -Override plugin configuration directory [@@CONFDIR@@/plugin-conf.d/]
653 +Override plugin configuration directory [@@NCONFDIR@@/plugin-conf.d/]
654  
655  =item B<< --libdir <dir> >>
656  
657 @@ -649,9 +649,9 @@ not this works with any particular devic
658  
659  =head1 FILES
660  
661 -    @@CONFDIR@@/munin-node.conf
662 -    @@CONFDIR@@/plugin-conf.d/*
663 -    @@CONFDIR@@/plugins/*
664 +    @@NCONFDIR@@/munin-node.conf
665 +    @@NCONFDIR@@/plugin-conf.d/*
666 +    @@NCONFDIR@@/plugins/*
667      @@LIBDIR@@/plugins/plugins.history
668      @@LIBDIR@@/plugins/*
669  
670 diff -urNpa munin-2.0.42.orig/node/sbin/munin-run munin-2.0.42/node/sbin/munin-run
671 --- munin-2.0.42.orig/node/sbin/munin-run       2018-10-11 15:24:44.286033000 +0000
672 +++ munin-2.0.42/node/sbin/munin-run    2018-10-11 15:25:02.399033000 +0000
673 @@ -35,7 +35,7 @@ use Munin::Node::Service;
674  
675  my $services;
676  my $servicedir;
677 -my $conffile = "$Munin::Common::Defaults::MUNIN_CONFDIR/munin-node.conf";
678 +my $conffile = "$Munin::Common::Defaults::MUNIN_NCONFDIR/munin-node.conf";
679  my $DEBUG    = 0;
680  my $PIDEBUG  = 0;
681  my $paranoia = 0;
682 @@ -98,7 +98,7 @@ sub main
683  sub parse_args
684  {
685      # Default configuration values
686 -    my $sconfdir   = "$Munin::Common::Defaults::MUNIN_CONFDIR/plugin-conf.d";
687 +    my $sconfdir   = "$Munin::Common::Defaults::MUNIN_NCONFDIR/plugin-conf.d";
688      my $sconffile;
689  
690      my ($plugin, $arg);
691 @@ -189,15 +189,15 @@ as they are under munin-node.
692  
693  =item B<< --config <configfile> >>
694  
695 -Use E<lt>fileE<gt> as configuration file. [@@CONFDIR@@/munin-node.conf]
696 +Use E<lt>fileE<gt> as configuration file. [@@NCONFDIR@@/munin-node.conf]
697  
698  =item B<< --servicedir <dir> >>
699  
700 -Use E<lt>dirE<gt> as plugin dir. [@@CONFDIR@@/plugins/]
701 +Use E<lt>dirE<gt> as plugin dir. [@@NCONFDIR@@/plugins/]
702  
703  =item B<< --sconfdir <dir> >>
704  
705 -Use E<lt>dirE<gt> as plugin configuration dir. [@@CONFDIR@@/plugin-conf.d/]
706 +Use E<lt>dirE<gt> as plugin configuration dir. [@@NCONFDIR@@/plugin-conf.d/]
707  
708  =item B<< --sconffile <file> >>
709  
710 @@ -230,9 +230,9 @@ Show version information.
711  
712  =head1 FILES
713  
714 -    @@CONFDIR@@/munin-node.conf
715 -    @@CONFDIR@@/plugins/*
716 -    @@CONFDIR@@/plugin-conf.d/*
717 +    @@NCONFDIR@@/munin-node.conf
718 +    @@NCONFDIR@@/plugins/*
719 +    @@NCONFDIR@@/plugin-conf.d/*
720      @@STATEDIR@@/munin-node.pid
721      @@LOGDIR@@/munin-node.log
722  
723 diff -urNpa munin-2.0.42.orig/node/sbin/munin-sched munin-2.0.42/node/sbin/munin-sched
724 --- munin-2.0.42.orig/node/sbin/munin-sched     2018-10-11 15:24:44.286033000 +0000
725 +++ munin-2.0.42/node/sbin/munin-sched  2018-10-11 15:25:02.399033000 +0000
726 @@ -34,8 +34,8 @@ use Munin::Node::Config;
727  use Munin::Node::ProxySpooler;
728  
729  my $servicedir;
730 -my $sconfdir = "$Munin::Common::Defaults::MUNIN_CONFDIR/plugin-conf.d";
731 -my $conffile = "$Munin::Common::Defaults::MUNIN_CONFDIR/munin-node.conf";
732 +my $sconfdir = "$Munin::Common::Defaults::MUNIN_NCONFDIR/plugin-conf.d";
733 +my $conffile = "$Munin::Common::Defaults::MUNIN_NCONFDIR/munin-node.conf";
734  my $spooldir = $Munin::Common::Defaults::MUNIN_SPOOLDIR;
735  
736  my ($host, $port);
737 @@ -164,7 +164,7 @@ and returning the output they produce.
738  
739  =item B<< --config <configfile> >>
740  
741 -Use E<lt>fileE<gt> as configuration file. [@@CONFDIR@@/munin-node.conf]
742 +Use E<lt>fileE<gt> as configuration file. [@@NCONFDIR@@/munin-node.conf]
743  
744  =item B< --[no]paranoia >
745  
746 @@ -182,9 +182,9 @@ View debug messages.  This can be very v
747  
748  =head1 FILES
749  
750 -    @@CONFDIR@@/munin-node.conf
751 -    @@CONFDIR@@/plugins/*
752 -    @@CONFDIR@@/plugin-conf.d/*
753 +    @@NCONFDIR@@/munin-node.conf
754 +    @@NCONFDIR@@/plugins/*
755 +    @@NCONFDIR@@/plugin-conf.d/*
756      @@STATEDIR@@/munin-sched.pid
757      @@LOGDIR@@/munin-sched.log
758  
759 diff -urNpa munin-2.0.42.orig/plugins/node.d/exim_mailqueue.in munin-2.0.42/plugins/node.d/exim_mailqueue.in
760 --- munin-2.0.42.orig/plugins/node.d/exim_mailqueue.in  2018-10-11 15:24:44.280033000 +0000
761 +++ munin-2.0.42/plugins/node.d/exim_mailqueue.in       2018-10-11 15:25:02.399033000 +0000
762 @@ -17,7 +17,7 @@ examine the queue directories.  This is
763    [exim_*]
764      user exim
765  
766 -Configuration parameters for a file in @@CONFDIR@@/plugin-conf.d/
767 +Configuration parameters for a file in @@NCONFDIR@@/plugin-conf.d/
768  if you need to override the defaults below:
769  
770    [exim_mailqueue]
771 diff -urNpa munin-2.0.42.orig/plugins/node.d/ipmi_sensor_.in munin-2.0.42/plugins/node.d/ipmi_sensor_.in
772 --- munin-2.0.42.orig/plugins/node.d/ipmi_sensor_.in    2018-10-11 15:24:44.280033000 +0000
773 +++ munin-2.0.42/plugins/node.d/ipmi_sensor_.in 2018-10-11 15:25:02.399033000 +0000
774 @@ -17,7 +17,7 @@ Inspired by code written by Peter Palfra
775  ipmitool probably needs to be run as root, and it may take more than
776  10 seconds on some hosts.
777  
778 -Add the following to your @@CONFDIR@@/munin-node:
779 +Add the following to your @@NCONFDIR@@/munin-node:
780  
781   [ipmi_sensor_*]
782    user root
783 @@ -49,7 +49,7 @@ with this program; if not, write to the
784  
785  =head1 BUGS
786  
787 -Plugin reads @@CONFDIR@@/ipmi directly, instead of reading environment
788 +Plugin reads @@NCONFDIR@@/ipmi directly, instead of reading environment
789  variables.
790  
791  =head1 MAGIC MARKERS
792 @@ -72,7 +72,7 @@ import re
793  CACHEDIR = environ['MUNIN_PLUGSTATE']
794  CACHEFILE = "plugin-ipmi_sensor.cache"
795  CACHEAGE = 120
796 -CONFIG = '@@CONFDIR@@/ipmi'
797 +CONFIG = '@@NCONFDIR@@/ipmi'
798  
799  
800  def normalize_sensor(name):
801 diff -urNpa munin-2.0.42.orig/plugins/node.d/mysql_innodb.in munin-2.0.42/plugins/node.d/mysql_innodb.in
802 --- munin-2.0.42.orig/plugins/node.d/mysql_innodb.in    2018-10-11 15:24:44.282033000 +0000
803 +++ munin-2.0.42/plugins/node.d/mysql_innodb.in 2018-10-11 15:25:02.399033000 +0000
804 @@ -34,7 +34,7 @@ the default INNODB tablespace, do the fo
805  
806  =head1 CONFIGURATION
807  
808 -Configuration parameters for @@CONFDIR@@/mysql_innodb,
809 +Configuration parameters for @@NCONFDIR@@/mysql_innodb,
810  if you need to override the defaults below:
811  
812   [mysql_innodb]
813 diff -urNpa munin-2.0.42.orig/plugins/node.d/mysql_isam_space_.in munin-2.0.42/plugins/node.d/mysql_isam_space_.in
814 --- munin-2.0.42.orig/plugins/node.d/mysql_isam_space_.in       2018-10-11 15:24:44.280033000 +0000
815 +++ munin-2.0.42/plugins/node.d/mysql_isam_space_.in    2018-10-11 15:25:02.399033000 +0000
816 @@ -8,7 +8,7 @@ on isam and myisam tables on a mysql ser
817  
818  =head1 CONFIGURATION
819  
820 -Configuration parameters for @@CONFDIR@@/PLUGIN,
821 +Configuration parameters for @@NCONFDIR@@/PLUGIN,
822  if you need to override the defaults below:
823  
824   [mysql_isam_space_*]
825 diff -urNpa munin-2.0.42.orig/plugins/node.d/mysql_threads.in munin-2.0.42/plugins/node.d/mysql_threads.in
826 --- munin-2.0.42.orig/plugins/node.d/mysql_threads.in   2018-10-11 15:24:44.280033000 +0000
827 +++ munin-2.0.42/plugins/node.d/mysql_threads.in        2018-10-11 15:25:02.399033000 +0000
828 @@ -9,7 +9,7 @@ mysql_threads - Plugin to monitor the nu
829  
830  =head1 CONFIGURATION
831  
832 -Configuration parameters for @@CONFDIR@@/mysql_threads, if you
833 +Configuration parameters for @@NCONFDIR@@/mysql_threads, if you
834  need to override the defaults below:
835  
836   [mysql_threads]
837 diff -urNpa munin-2.0.42.orig/plugins/node.d/named.in munin-2.0.42/plugins/node.d/named.in
838 --- munin-2.0.42.orig/plugins/node.d/named.in   2018-10-11 15:24:44.280033000 +0000
839 +++ munin-2.0.42/plugins/node.d/named.in        2018-10-11 15:25:02.399033000 +0000
840 @@ -34,7 +34,7 @@ restrictions on the log file.
841  
842  =head1 CONFIGURATION
843  
844 -Configuration parameters for @@CONFDIR@@/named,
845 +Configuration parameters for @@NCONFDIR@@/named,
846  if you need to override the defaults below:
847  
848   [named]
849 diff -urNpa munin-2.0.42.orig/plugins/node.d/ntp_kernel_pll_freq.in munin-2.0.42/plugins/node.d/ntp_kernel_pll_freq.in
850 --- munin-2.0.42.orig/plugins/node.d/ntp_kernel_pll_freq.in     2018-10-11 15:24:44.282033000 +0000
851 +++ munin-2.0.42/plugins/node.d/ntp_kernel_pll_freq.in  2018-10-11 16:30:23.898033000 +0000
852 @@ -12,7 +12,7 @@ the NTP status
853  
854  No configuration
855  
856 -This plugin optionally reads the file @@CONFDIR@@/ntp-freq-comp, which
857 +This plugin optionally reads the file @@NCONFDIR@@/ntp-freq-comp, which
858  should contain a number to be added to the frequency read by ntpdc.
859  
860  =head1 AUTHORS
861 @@ -46,8 +46,8 @@ if [ "$1" = "autoconf" ]; then
862      exit 0
863  fi
864  
865 -if [ -f "@@CONFDIR@@/ntp-freq-comp" ]; then
866 -    fcomp=$(cat "@@CONFDIR@@/ntp-freq-comp")
867 +if [ -f "@@NCONFDIR@@/ntp-freq-comp" ]; then
868 +    fcomp=$(cat "@@NCONFDIR@@/ntp-freq-comp")
869  else
870      fcomp=0
871  fi
872 diff -urNpa munin-2.0.42.orig/plugins/node.d/postfix_mailstats.in munin-2.0.42/plugins/node.d/postfix_mailstats.in
873 --- munin-2.0.42.orig/plugins/node.d/postfix_mailstats.in       2018-10-11 15:24:44.281033000 +0000
874 +++ munin-2.0.42/plugins/node.d/postfix_mailstats.in    2018-10-11 15:25:02.400033000 +0000
875 @@ -8,7 +8,7 @@ rejected by postfix
876  
877  =head1 CONFIGURATION
878  
879 -Configuration parameters for @@CONFDIR@@/postfix_mailstats,
880 +Configuration parameters for @@NCONFDIR@@/postfix_mailstats,
881  if you need to override the defaults below:
882  
883   [postfix_mailstats]
884 diff -urNpa munin-2.0.42.orig/plugins/node.d/psu_.in munin-2.0.42/plugins/node.d/psu_.in
885 --- munin-2.0.42.orig/plugins/node.d/psu_.in    2018-10-11 15:24:44.281033000 +0000
886 +++ munin-2.0.42/plugins/node.d/psu_.in 2018-10-11 15:25:02.400033000 +0000
887 @@ -15,7 +15,7 @@ we wish to graph.
888  
889  Example:
890  
891 - ln -s @@LIBDIR@@/plugins/psu_ @@CONFDIR@@/plugins/psu_foo
892 + ln -s @@LIBDIR@@/plugins/psu_ @@NCONFDIR@@/plugins/psu_foo
893  
894  ...will monitor the user "foo"
895  
896 diff -urNpa munin-2.0.42.orig/plugins/node.d/squeezebox_.in munin-2.0.42/plugins/node.d/squeezebox_.in
897 --- munin-2.0.42.orig/plugins/node.d/squeezebox_.in     2018-10-11 15:24:44.282033000 +0000
898 +++ munin-2.0.42/plugins/node.d/squeezebox_.in  2018-10-11 15:25:02.400033000 +0000
899 @@ -20,7 +20,7 @@ SqueezeCenter. If the plugin is run from
900  non-default configuration, please use the environment variables
901  'squeezebox_host' and 'squeezebox_port' to connect. Also, if your
902  nc(1) binary is not called "nc", or not the one in $PATH, please define it
903 -in the plugin's environment file (@@CONFDIR@@/squeezebox or similar).
904 +in the plugin's environment file (@@NCONFDIR@@/squeezebox or similar).
905  
906  Sample follows:
907  
908 diff -urNpa munin-2.0.42.orig/plugins/node.d/varnish_.in munin-2.0.42/plugins/node.d/varnish_.in
909 --- munin-2.0.42.orig/plugins/node.d/varnish_.in        2018-10-11 15:24:44.282033000 +0000
910 +++ munin-2.0.42/plugins/node.d/varnish_.in     2018-10-11 15:25:02.400033000 +0000
911 @@ -54,7 +54,7 @@ session, session_herd
912  You can link them yourself with something like this:
913  
914    ln -s @@LIBDIR@@/plugins/varnish_ \
915 -    @@CONFDIR@@/plugins/varnish_data_structures
916 +    @@NCONFDIR@@/plugins/varnish_data_structures
917  
918  =head1 INTERPRETATION
919  
920 diff -urNpa munin-2.0.42.orig/plugins/node.d.cygwin/df.in munin-2.0.42/plugins/node.d.cygwin/df.in
921 --- munin-2.0.42.orig/plugins/node.d.cygwin/df.in       2018-10-11 15:24:44.277033000 +0000
922 +++ munin-2.0.42/plugins/node.d.cygwin/df.in    2018-10-11 15:25:02.400033000 +0000
923 @@ -13,7 +13,7 @@ Cygwin 1.7.x or higher systems with core
924  
925  =head1 USAGE
926  
927 -Link this plugin to @@CONFDIR@@/plugins/ and restart the munin-node.
928 +Link this plugin to @@NCONFDIR@@/plugins/ and restart the munin-node.
929  
930  The plugin excludes per default the following special, read-only or
931  dynamically allocating file systems from graphing:
932 diff -urNpa munin-2.0.42.orig/plugins/node.d.debug/if.in munin-2.0.42/plugins/node.d.debug/if.in
933 --- munin-2.0.42.orig/plugins/node.d.debug/if.in        2018-10-11 15:24:44.277033000 +0000
934 +++ munin-2.0.42/plugins/node.d.debug/if.in     2018-10-11 15:25:02.400033000 +0000
935 @@ -21,7 +21,7 @@ variable.  For example:
936  
937  =head1 USAGE
938  
939 -Link this plugin to @@CONFDIR@@/plugins/ and restart the munin-node.
940 +Link this plugin to @@NCONFDIR@@/plugins/ and restart the munin-node.
941  
942  =head1 MAGIC MARKERS
943  
944 diff -urNpa munin-2.0.42.orig/plugins/node.d.debug/tc.in munin-2.0.42/plugins/node.d.debug/tc.in
945 --- munin-2.0.42.orig/plugins/node.d.debug/tc.in        2018-10-11 15:24:44.277033000 +0000
946 +++ munin-2.0.42/plugins/node.d.debug/tc.in     2018-10-11 15:25:02.400033000 +0000
947 @@ -21,7 +21,7 @@ For example:
948  
949  =head1 USAGE
950  
951 -Link this plugin to @@CONFDIR@@/plugins/ and restart the munin-node.
952 +Link this plugin to @@NCONFDIR@@/plugins/ and restart the munin-node.
953  
954  =head1 MAGIC MARKERS
955  
956 diff -urNpa munin-2.0.42.orig/plugins/node.d.linux/acpi.in munin-2.0.42/plugins/node.d.linux/acpi.in
957 --- munin-2.0.42.orig/plugins/node.d.linux/acpi.in      2018-10-11 15:24:44.278033000 +0000
958 +++ munin-2.0.42/plugins/node.d.linux/acpi.in   2018-10-11 15:25:02.401033000 +0000
959 @@ -17,7 +17,7 @@ Load the 'thermal' kernel module and the
960  
961  =head1 USAGE
962  
963 -Link this plugin to @@CONFDIR@@/plugins/ and restart the munin-node.
964 +Link this plugin to @@NCONFDIR@@/plugins/ and restart the munin-node.
965  
966  =head1 INTERPRETATION
967  
968 diff -urNpa munin-2.0.42.orig/plugins/node.d.linux/apt.in munin-2.0.42/plugins/node.d.linux/apt.in
969 --- munin-2.0.42.orig/plugins/node.d.linux/apt.in       2018-10-11 15:24:44.278033000 +0000
970 +++ munin-2.0.42/plugins/node.d.linux/apt.in    2018-10-11 15:25:02.401033000 +0000
971 @@ -38,7 +38,7 @@ Remember to randomize when these cronjob
972  
973  =head1 USAGE
974  
975 -Link this plugin in @@CONFDIR@@/plugins/ and restart the munin-node.
976 +Link this plugin in @@NCONFDIR@@/plugins/ and restart the munin-node.
977  
978  =head1 NOTES
979  
980 diff -urNpa munin-2.0.42.orig/plugins/node.d.linux/df.in munin-2.0.42/plugins/node.d.linux/df.in
981 --- munin-2.0.42.orig/plugins/node.d.linux/df.in        2018-10-11 15:24:44.278033000 +0000
982 +++ munin-2.0.42/plugins/node.d.linux/df.in     2018-10-11 15:25:02.401033000 +0000
983 @@ -31,7 +31,7 @@ This configuration snipplet is an exampl
984      env.warning 92
985      env.critical 98
986  
987 -Put it in a file in @@CONFDIR@@/plugin-conf.d/ and restart the munin-node.
988 +Put it in a file in @@NCONFDIR@@/plugin-conf.d/ and restart the munin-node.
989  
990  You may specify filesystem specific warning and critical levels:
991  
992 @@ -58,7 +58,7 @@ RE will not be included.
993  
994  =head1 USAGE
995  
996 -Link this plugin to @@CONFDIR@@/plugins/ and restart the munin-node.
997 +Link this plugin to @@NCONFDIR@@/plugins/ and restart the munin-node.
998  
999  =head1 MAGIC MARKERS
1000  
1001 diff -urNpa munin-2.0.42.orig/plugins/node.d.linux/df_inode.in munin-2.0.42/plugins/node.d.linux/df_inode.in
1002 --- munin-2.0.42.orig/plugins/node.d.linux/df_inode.in  2018-10-11 15:24:44.278033000 +0000
1003 +++ munin-2.0.42/plugins/node.d.linux/df_inode.in       2018-10-11 15:25:02.401033000 +0000
1004 @@ -28,7 +28,7 @@ This configuration snipplet is an exampl
1005      env.warning 92
1006      env.critical 98
1007  
1008 -Put it in a file in @@CONFDIR@@/plugin-conf.d/ and restart the munin-node.
1009 +Put it in a file in @@NCONFDIR@@/plugin-conf.d/ and restart the munin-node.
1010  
1011  You may specify filesystem specific warning and critical levels:
1012  
1013 @@ -55,7 +55,7 @@ RE will not be included.
1014  
1015  =head1 USAGE
1016  
1017 -Link this plugin to @@CONFDIR@@/plugins/ and restart the munin-node.
1018 +Link this plugin to @@NCONFDIR@@/plugins/ and restart the munin-node.
1019  
1020  =head1 MAGIC MARKERS
1021  
1022 diff -urNpa munin-2.0.42.orig/plugins/node.d.linux/fw_conntrack.in munin-2.0.42/plugins/node.d.linux/fw_conntrack.in
1023 --- munin-2.0.42.orig/plugins/node.d.linux/fw_conntrack.in      2018-10-11 15:24:44.278033000 +0000
1024 +++ munin-2.0.42/plugins/node.d.linux/fw_conntrack.in   2018-10-11 15:25:02.401033000 +0000
1025 @@ -11,7 +11,7 @@ This plugin must run with root privilege
1026  
1027  =head2 CONFIGURATION EXAMPLE
1028  
1029 -@@CONFDIR@@/plugin-conf.d/global or other file in that dir must contain:
1030 +@@NCONFDIR@@/plugin-conf.d/global or other file in that dir must contain:
1031  
1032   [fw_*]
1033    user root
1034 diff -urNpa munin-2.0.42.orig/plugins/node.d.linux/fw_forwarded_local.in munin-2.0.42/plugins/node.d.linux/fw_forwarded_local.in
1035 --- munin-2.0.42.orig/plugins/node.d.linux/fw_forwarded_local.in        2018-10-11 15:24:44.278033000 +0000
1036 +++ munin-2.0.42/plugins/node.d.linux/fw_forwarded_local.in     2018-10-11 15:25:02.401033000 +0000
1037 @@ -10,7 +10,7 @@ This plugin must run with root privilege
1038  
1039  =head2 CONFIGURATION EXAMPLE
1040  
1041 -@@CONFDIR@@/plugin-conf.d/global or other file in that dir must contain:
1042 +@@NCONFDIR@@/plugin-conf.d/global or other file in that dir must contain:
1043  
1044   [fw_*]
1045    user root
1046 diff -urNpa munin-2.0.42.orig/plugins/node.d.linux/fw_packets.in munin-2.0.42/plugins/node.d.linux/fw_packets.in
1047 --- munin-2.0.42.orig/plugins/node.d.linux/fw_packets.in        2018-10-11 15:24:44.278033000 +0000
1048 +++ munin-2.0.42/plugins/node.d.linux/fw_packets.in     2018-10-11 15:25:02.401033000 +0000
1049 @@ -14,7 +14,7 @@ This plugin must run with root privilege
1050  
1051  =head1 CONFIGURATION EXAMPLE
1052  
1053 -@@CONFDIR@@/plugin-conf.d/global or other file in that dir must contain:
1054 +@@NCONFDIR@@/plugin-conf.d/global or other file in that dir must contain:
1055  
1056   [fw*]
1057    user root
1058 diff -urNpa munin-2.0.42.orig/plugins/node.d.linux/iostat.in munin-2.0.42/plugins/node.d.linux/iostat.in
1059 --- munin-2.0.42.orig/plugins/node.d.linux/iostat.in    2018-10-11 15:24:44.279033000 +0000
1060 +++ munin-2.0.42/plugins/node.d.linux/iostat.in 2018-10-11 15:25:02.401033000 +0000
1061 @@ -24,7 +24,7 @@ guest OS/dom-U IO-traffic originates in.
1062  
1063  =head1 USAGE
1064  
1065 -Link this plugin to @@CONFDIR@@/plugins/ and restart the munin-node.
1066 +Link this plugin to @@NCONFDIR@@/plugins/ and restart the munin-node.
1067  
1068  =head1 INTERPRETATION
1069  
1070 diff -urNpa munin-2.0.42.orig/plugins/node.d.linux/iostat_ios.in munin-2.0.42/plugins/node.d.linux/iostat_ios.in
1071 --- munin-2.0.42.orig/plugins/node.d.linux/iostat_ios.in        2018-10-11 15:24:44.278033000 +0000
1072 +++ munin-2.0.42/plugins/node.d.linux/iostat_ios.in     2018-10-11 15:25:02.401033000 +0000
1073 @@ -15,7 +15,7 @@ None needed
1074  
1075  =head1 USAGE
1076  
1077 -Link this into @@CONFDIR@@/plugins/ and restart the munin-node.
1078 +Link this into @@NCONFDIR@@/plugins/ and restart the munin-node.
1079  
1080  =head1 INTERPRETATION
1081  
1082 diff -urNpa munin-2.0.42.orig/plugins/node.d.linux/irqstats.in munin-2.0.42/plugins/node.d.linux/irqstats.in
1083 --- munin-2.0.42.orig/plugins/node.d.linux/irqstats.in  2018-10-11 15:24:44.278033000 +0000
1084 +++ munin-2.0.42/plugins/node.d.linux/irqstats.in       2018-10-11 15:25:02.401033000 +0000
1085 @@ -18,7 +18,7 @@ None needed
1086  
1087  =head1 USAGE
1088  
1089 -Link this plugin to @@CONFDIR@@/plugins/ and restart the munin-node.
1090 +Link this plugin to @@NCONFDIR@@/plugins/ and restart the munin-node.
1091  
1092  =head1 INTERPRETATION
1093  
1094 diff -urNpa munin-2.0.42.orig/resources/hpux-init.d_munin-node.in munin-2.0.42/resources/hpux-init.d_munin-node.in
1095 --- munin-2.0.42.orig/resources/hpux-init.d_munin-node.in       2018-10-11 15:24:44.287033000 +0000
1096 +++ munin-2.0.42/resources/hpux-init.d_munin-node.in    2018-10-11 15:25:02.402033000 +0000
1097 @@ -6,7 +6,7 @@
1098  PATH=/sbin:/bin:/usr/sbin:/usr/bin
1099  NAME=munin-node
1100  DAEMON=@@SBINDIR@@/$NAME
1101 -CONFFILE=@@CONFDIR@@/munin-node.conf
1102 +CONFFILE=@@NCONFDIR@@/munin-node.conf
1103  RUN_AS=$(awk '$1~/user/{print$2}' $CONFFILE)
1104  PIDFILE=$(awk '$1~/pid/{print$2}' $CONFFILE)
1105  MYCONF=/etc/rc.config.d/muninconf
1106 diff -urNpa munin-2.0.42.orig/resources/linux-cron.d_munin-node.in munin-2.0.42/resources/linux-cron.d_munin-node.in
1107 --- munin-2.0.42.orig/resources/linux-cron.d_munin-node.in      2018-10-11 15:24:44.287033000 +0000
1108 +++ munin-2.0.42/resources/linux-cron.d_munin-node.in   2018-10-11 15:25:02.402033000 +0000
1109 @@ -8,5 +8,5 @@ MAILTO=root
1110  # an hour (12 invokations an hour, 1 in 12 chance that the update will
1111  # happen), but ensure that there will never be more than two hour (7200
1112  # seconds) interval between updates..
1113 -*/5 * * * *    root [ -x @@CONFDIR@@/plugins/apt ] && @@CONFDIR@@/plugins/apt update 7200 12 >/dev/null
1114 +*/5 * * * *    root [ -x @@NCONFDIR@@/plugins/apt ] && @@NCONFDIR@@/plugins/apt update 7200 12 >/dev/null
1115  
1116 diff -urNpa munin-2.0.42.orig/t/Makefile.config munin-2.0.42/t/Makefile.config
1117 --- munin-2.0.42.orig/t/Makefile.config 2018-10-11 15:24:44.287033000 +0000
1118 +++ munin-2.0.42/t/Makefile.config      2018-10-11 15:25:02.402033000 +0000
1119 @@ -9,7 +9,8 @@
1120  PREFIX     = $(PWD)/t/install
1121  
1122  # Where Munin keeps its configurations (server.conf, client.conf, ++)
1123 -CONFDIR    = $(PREFIX)/etc
1124 +MCONFDIR    = $(PREFIX)/etc
1125 +NCONFDIR    = $(PREFIX)/etc
1126  
1127  # Client only - Where to put RRD files and other intenal data
1128  DBDIR      = $(PREFIX)/var/lib