[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: What's usefulness of monitor backend?

Sorry for taking so long to type this up...

This was actually an effort based on two different websites, and my own
hacking. I will provide a summary of what I did here, the relevant
websites are:

CVS area for the scripts mentioned here:

Jehan Procaccia's original instructions (in french) here:

A slightly modified approach and script here, by Andrew J Cosgriff:


There are a few things that you need in order to do this, I cannot
cover how to install these things, as this is outside of the scope of
this mailing list and there are a number of documents online how to do

The base minimum you will need installed and working: SNMP, mrtg, and
a perl installation with the following modules: libhtml-parser-perl,
libwww-perl, libhtml-tree-perl, libnet-ldap-perl, libfilter-perl,
libparse-recdescent-perl, switch.pm

If you are using debian stable, the packages that you would get are:
mrtg, snmpd, libhtml-parser-perl, libwww-perl, libhtml-tree-perl,
libnet-ldap-perl, libfilter-perl, libparse-recdescent-perl

In addition the debian stable perl module Switch.pm is deprecated and
does not work (in fact it is just a shell). You will need to do
dh-make-perl --build --install --cpan Switch.pm to get this properly
installed on your system.

You will also need this script: 

You need to modify these variables in this script: $DNConn, $PassConn,
$Serveur, $Port

Set up your snmpd.conf file to have a number of exec lines according
to what you want to monitor, you can take this one and put it in your
snmpd.conf (but be sure to change the community strings at the top!)
and then reload your snmpd:

snmpd.conf relevant pieces:

You then need to set up your mrtg.cfg, you can use the following one
as a guide, you need to make sure you change the community string for
each entry so that it matches what you have in your readonly community
string in your snmpd.conf, you also need to change the hostname after
each one, and set a normal directory:

mrtg.cfg relevant pieces:

Each Target entry has two "oids" separated by an ampersand, the oids
begin with . and then have one more octect
after it, each number corresponds to the number of the "exec" line in
the snmpd.conf (the first exec line is .1, so the full oid is:
., the second exec line is .2, so its full
oid is: ., etc.). So if you want to change
what two elements you want to graph, you can change these oids to be
what you want to graph. I kinda half-blind made a guess what would
produce the most interesting graphs.

MRTG requires two numbers to make a graph, so some of my graphs only
are graphing one LDAP statisitc, so I had to spit out a 0, thats what
the "echozero" script is at:


On Thu, 12 Feb 2004, Quanah Gibson-Mount wrote:

> --On Thursday, February 12, 2004 12:16 AM -0600 Micah Anderson 
> <micah@riseup.net> wrote:
> >I find it very useful: http://riseup.net/mrtg/buffy_slapd
> >
> I second Turbo's bit... Please share? :)
> --Quanah
> --
> Quanah Gibson-Mount
> Principal Software Developer
> ITSS/TSS/Computing Systems
> ITSS/TSS/Infrastructure Operations
> Stanford University
> GnuPG Public Key: http://www.stanford.edu/~quanah/pgp.html