Re: Squid & MRTG possible?

From: Nikos Mouat <nikm@dont-contact.us>
Date: Tue, 17 Nov 1998 11:11:59 -0800 (PST)

Hi.
   I needed to tinker with MRTG a little bit to make things work on the
latest version (which allows you to specify port #'s) - it tries to lookup
a device name:

          ($in,$out,$uptime,$name) =
            &snmpget($$target{$targ}{'router'},
                     $$target{$targ}{'community'},
                     $$target{$targ}{'oid1'},
                     $$target{$targ}{'oid2'},
                     'sysUptime',
                     'sysName');

and squid doesn't contain that information (or atleast MRTG choked trying
to get that information from my server). I changed the line above to be:

          ($in,$out) =
            &snmpget($$target{$targ}{'router'},
                     $$target{$targ}{'community'},
                     $$target{$targ}{'oid1'},
                     $$target{$targ}{'oid2'});

and along with some other stuff from the patch (hard coding the squid
oid's) things work just peachy.

nm

On Tue, 17 Nov 1998, Alan J. Flavell wrote:

> On Tue, 17 Nov 1998, Matija Grabnar wrote:
>
> > You need to patch MRTG to get the data from the correct SNMP port for
> > Squid 2.0.
>
> No, you don't need to patch it: you need to get the current version of
> MRTG, and use its facilities for specifying the SNMP port in your
> configuration file. That way, you can have different SNMP port
> numbers for different plots (9161 for mrouted, for example ;-)
>
> all the best
>
Received on Tue Nov 17 1998 - 12:06:34 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:43:08 MST