Munin

m (Installing On Diablo: Diablo link)
(Installing On Diablo)
Line 13: Line 13:
==Installing On Diablo==
==Installing On Diablo==
-
[[Open development/Maemo roadmap/Diablo|Diablo]] is effectively a relatively the old Serge release of arm debian linux, so you have to get the packages from a debian archive.
+
[[Open development/Maemo roadmap/Diablo|Diablo]] is effectively a relatively old release (Serge) of arm debian linux, so you have to get the packages from a debian archive.
Login as root to a command shell and fetch the packages. You probably want to fetch them to your flash memory card rather than clutter up the system file space.
Login as root to a command shell and fetch the packages. You probably want to fetch them to your flash memory card rather than clutter up the system file space.

Revision as of 16:23, 12 May 2010

Contents

How To Install Munin Node

Munin is a system measuring tool which gives the user a wide range of graphs spanning hours, days, weeks and months. An example set of some graphs are shown here.

(note: I shall upload some graphs of my own when I have collected data long enough)

Munin is much loved in the SysAdmin community because of its flexibility and the way it can be extended by writing plugins for the monitored systems, and particularly because the plugins are very easy to write, with a community resource for sharing them.

Each system being monitored runs "munin node", a simple daemon that listens on TCP port 4949 for connections, and if one comes from a permitted host or network, presents different kinds of information to it as requested.

Installing it on Maemo is quite easy as it's architecture independent, being basically a perl process which invokes scripts. The only trick is knowing to bypass certain dependencies during installation, and a few tweaks in the configuration. The installation has to happen from the command line as root.

Installing On Diablo

Diablo is effectively a relatively old release (Serge) of arm debian linux, so you have to get the packages from a debian archive.

Login as root to a command shell and fetch the packages. You probably want to fetch them to your flash memory card rather than clutter up the system file space.

fetch the packages as follows

# cd /media/external/download
# wget http://ftp.de.debian.org/archive/debian/pool/main/a/adduser/adduser_3.63_all.deb
# wget http://ftp.ch.debian.org/debian-archive/pool/main/m/munin/munin-node_1.2.3-1_all.deb
# wget http://ftp.ch.debian.org/debian-archive/pool/main/libn/libnet-server-perl/libnet-server-perl_0.87-3sarge1_all.deb
# wget http://ftp.ch.debian.org/debian-archive/pool/main/libi/libio-multiplex-perl/libio-multiplex-perl_1.08-1_all.deb

Once fetched, install them thus

# dpkg -i adduser_3.63_all.deb
# dpkg -i --ignore-depends=perl libio-multiplex-perl_1.08-1_all.deb
# dpkg -i --ignore-depends=perl libnet-server-perl_0.87-3sarge1_all.deb
# dpkg -i --ignore-depends=perl munin-node_1.2.3-1_all.deb

The reason we have to tell dpkg to ignore the dependency on perl is because the tablet has "perl-base" package instead which has everything needed.

One thing the tablet doesn't have is "pgrep", a simple command line tool, it doesn't really matter, but can anyone help with a suitable place it can be installed from, or a simple substitute script?

Configuration

The only things you need to do are to permit your munin master monitoring machine to contact your tablet, to set the host name, and to restart munin-node.

The munin node configuration is a imple text file called /etc/munin/munin-node.conf

Firstly, add more "allow" lines such as this one so that your local network can talk to the munin daemon; the example adds 192.168.29.* but has to be written in perl regex format.

allow ^192\.168\.1\.\d+$

then override the host name, the munin master node's configuration expectation of the host name MUST match the tablet's host name. If you call your tablet gorgonzola, the line would read thus:

host_name gorgonzola

Save your edits, and at the command line type

/etc/init.d/munin-node restart

Testing the installation

Verify you can now talk to your tablet from the munin master node thus by firing up a shell and typing the words in bold:

    # telnet gorgonzola.example.com 4949
    Trying 192.168.1.2...
    Connected to gorgonzola.
    Escape character is '^]'.
    # munin node at gorgonzola
    list
    open_inodes irqstats entropy processes df interrupts if_err_wlan0 swap load cpu df_inode forks iostat open_files if_wlan0 memory
    fetch cpu
    user.value 127603
    nice.value 1478
    system.value 44203
    idle.value 4097098
    iowait.value 1878
    irq.value 278
    softirq.value 2228
    .
    quit
    Connection closed by foreign host.

Configuring the Munin Master

You configure the munin master exactly as per the munin documentation; simply add the tablet to the /etc/munin/munin.conf file like this

[gorgonzola]
    address gorgonzola.example.com
    use_node_name yes

You could of course use the IP address instead - it would go on the "address" line e.g. "address 192.168.1.2"

You don't need to restart anything, the next time munin runs it will pick up the changes. If you have done it correctly the graphs will begin to appear in about ten minutes as tiny specks on the right. There are troubleshooting pages on the munin wiki.

Good luck and enjoy your newly-metered tablet!

Retrieved from "http://bugs.maemo.org/Munin"