Monitoring Multiple Systems With munin (Debian Etch)

Version 1.0
Author: Falko Timme

In this article I will describe how you can monitor multiple systems with munin. munin produces nifty little graphics about nearly every aspect of your server (load average, memory usage, CPU usage, MySQL throughput, eth0 traffic, etc.) without much configuration. I will install the munin client on all systems that are to be monitored (including the munin server itself); the munin clients will then report to the munin server.

This tutorial was written for Debian Etch, but the configuration should apply to other distributions with little changes as well.

I want to say first that this is not the only way of setting up such a system. There are many ways of achieving this goal but this is the way I take. I do not issue any guarantee that this will work for you!


1 Preliminary Note

Our munin server's hostname is (IP address:, and we have a web site on it with the document root /var/www/ on it.

I'm using one munin client here, (IP address: Of course, you can add as many client systems as you like.


2 Install And Configure munin On The Server

munin server (

To install the munin client and server on Debian Etch, we do this:

apt-get install munin munin-node

Next, we must edit the munin configuration file /etc/munin/munin.conf. We want munin to put its output into the directory /var/www/, therefore we change the value of htmldir, and we want it to use the name instead of localhost.localdomain in the HTML output, therefore we replace localhost.localdomain with With this configuration, the munin server is able to monitor itself. Without the comments, the changed file looks like this:

vi /etc/munin/munin.conf

dbdir   /var/lib/munin
htmldir /var/www/
logdir  /var/log/munin
rundir  /var/run/munin

tmpldir /etc/munin/templates

    use_node_name yes

Next we create the directory /var/www/ and change its ownership to the user and group munin, otherwise munin cannot place its output in that directory. Then we restart munin:

mkdir -p /var/www/
chown munin:munin /var/www/
/etc/init.d/munin-node restart

Now wait a few minutes so that munin can produce its first output, and then go to in your browser, and you see the first statistics. After a few days this could look like this:

(This is just a small excerpt of the many graphics that munin produces...)


3 Password-Protect The munin Output Directory On The munin Server (Optional)

munin server (

Now it is a good idea to password-protect the directory /var/www/ unless you want everybody to be able to see every little statistic about your server.

To do this, we create an .htaccess file in /var/www/

vi /var/www/

AuthType Basic
AuthName "Members Only"
AuthUserFile /var/www/
<limit GET PUT POST>
require valid-user

Then we must create the password file /var/www/ We want to log in with the username admin, so we do this:

htpasswd -c /var/www/ admin

Enter a password for admin, and you're done!


4 Install And Configure munin On The Client

munin client (

On the client system, we only have to install the munin client package which is called munin-node:

apt-get install munin-node

Next we must tell the munin client that our munin server with the IP address is allowed to connect to retrieve details from the client. To do this, we open /etc/munin/munin-node.conf and add the line allow ^192\.168\.0\.100$ at the bottom of it. Afterwards, the file should look like this:

vi /etc/munin/munin-node.conf

# Example config-file for munin-node

log_level 4
log_file /var/log/munin/munin-node.log
port 4949
pid_file /var/run/munin/
background 1
setseid 1

# Which port to bind to;
host *
user root
group root
setsid yes

# Regexps for files to ignore

ignore_file ~$
ignore_file \.bak$
ignore_file %$
ignore_file \.dpkg-(tmp|new|old|dist)$
ignore_file \.rpm(save|new)$

# Set this if the client doesn't report the correct hostname when
# telnetting to localhost, port 4949
#host_name localhost.localdomain

# A list of addresses that are allowed to connect.  This must be a
# regular expression, due to brain damage in Net::Server, which
# doesn't understand CIDR-style network notation.  You may repeat
# the allow line as many times as you'd like

allow ^127\.0\.0\.1$
allow ^192\.168\.0\.100$

Finally, we restart the munin client:

/etc/init.d/munin-node restart


5 Update The munin Server Configuration

munin server (

Now we must tell the munin server that there's another system to monitor ( with the IP address To do this, we open /etc/munin/munin.conf and add a stanza for so that the file looks like this:

vi /etc/munin/munin.conf

dbdir   /var/lib/munin
htmldir /var/www/
logdir  /var/log/munin
rundir  /var/run/munin

tmpldir /etc/munin/templates

    use_node_name yes

    use_node_name yes

Next, we restart munin:

/etc/init.d/munin-node restart

After a few minutes, you should find a link for on the munin page (

When you click on that link, you will see the graphs for


Share this page:

4 Comment(s)

Add comment


From: Songomem


I do the installation an it's was great.

But two months later, I have to change munin master  to another server. 

How I can do this, saving all the data.???  beacause if I only copy the html files, allways erase the information...



From: l33tmyst

Copy /var/lib/munin

From: Neil Batchelor

The second code excert in step three is missing /web/monitoring/ otherwise the whole website will be password protected.

From: naksu


I do the installation an it's was great.

But i can´t get data from multiple servers, what i made wrong?