master: whitespace fix in Utils.pm
master: avoid having 2 concurrent $htmlconfig
master: undef the config pre-reload (frees mem)
master: RAM usage for $cache
node: don't ignore timeout config option

According to pwydrych in ticket #1258 :

Adding timeout to munin-node.conf has no effect:

    $ grep timeout /etc/opt/munin/munin-node.conf
    timeout 240

    $ sudo /opt/munin/sbin/munin-node

    $ telnet 127.0.0.1 4949
    Trying 127.0.0.1...
    Connected to localhost.
    Escape character is '^]'.
    # munin node at [***]
    Connection closed by foreign host.

    $ egrep 'Peer|timeout' /opt/munin/log/munin/munin-node.log
    2012/09/18-08:48:49 CONNECT TCP Peer: "127.0.0.1:22230" Local: "127.0.0.1:4949"
    2012/09/18-08:49:49 [91860] Node side timeout while processing: '<no command received yet>'

The variable is not passed to Munin::Node::Service->new:

    $ cat -n node/sbin/munin-node
    [...]
        67      my $services = Munin::Node::Service->new(
        68          servicedir => $servicedir,
        69          defuser    => $config->{defuser},
        70          defgroup   => $config->{defgroup},
        71          pidebug    => $PIDEBUG,
        72      );
    [...]

Closes: #1258
plugins/apt: fix plugin statedir for cron

The apt plugin has its state updated in cron. There the ENV var
MUNIN_PLUGSTATE doesn't exist, so we need to set a default.

Completes d53b34d1bdfafece48e50f2d690b2e1130b6f1dd, to do the same,
but for apt plugin.

Closes: D#687912
plugins/bonding_err_: adjust for newer kernels
html: fix bug introduced by 1aec747c10

Commit 1aec747c10f0d5077842294ca351b918b77fb1e9 failed to address the fix in
789c59e3a27f5d38cabd02c8f57fec605e6146a8 fully. So we somewhat revert
1aec747c10 in stable-2.0.

Yet, as 1aec747c10 is a big performance enhancer, it might be a good idea to
rework on it in devel. But for stable-2.0, the performance hit is acceptable.

Closes: D:689291
graph: remove all extra INFO messages

The start/stop logs are now just plain wrong. Removing them in stable-2.0, as
they are wasting quite a huge diskspace, for almost no value.

And postpone a proper logging scheme for devel.

Closes: #1251
plugins/proc: fix bug in selecting via uid
dev_scripts: remove warnings

This isn't strictly a bugfix, but it is low risk as it does only
impact dev_scripts.
graph: remote superfluous -T in cmdline

munin-graph runs from cron, so -T is uneeded.

It is even harmful, since -T makes it ignore environnement vars. And
it is the only cron-runned part that uses it, as the code origins as
a fork of munin-cgi-graph.
Merge branch 'fix-minor' into stable-2.0
master: fix TLS enabled updates

As Christian Schroetter reported TLS updates do not work anymore
in 2.0.

This was due to a bug accurately pinpointed by Eero Häkkinen :

   The fetch_service_config method in the file Master/Node.pm is
   changed to use the new _node_read_fast() method which uses
   sysread for reading from a socket and bypasses the TLS layer
   completely.

This commit delegate a _node_read_fast() call to _node_read()
when tls is enabled.

Closes: D:699803
2.0.12
master: remove weaken on storable::read

6d62e6b0782ecfa0f4e0c2bec14434d675734962 introduced a weaken_config() sub, used
in munin_readconfig_storable().  It should not be needed, and some profiling
showed that it is a *huge* cpu eater.
master: remove auto_weaken()

Every weaken() should be done on construction time. Fixing it afterwards is
wrong, and might be dangerous. Let bug leaks happen and be fixed !
contrib: add a test for memory leaks
contrib: complete test with Storable dump/load

Test if Storable also saves the "weak" state.

Hint: it does.
Use a more efficient sort on the list of nodes

 - Cache the subroutine results, to improve speed when comparing.  More
   noticeable on a large number of nodes.