squid and mrtg.

From: Sys Admin <[email protected]>
Date: Wed, 19 Jan 2000 17:01:36 -0500 (EST)

i know this isn't the correct list, but...i haven't seen a thread on the
squid-snmp list in a while nor did i see a thread that answers my
question in that archive.

setup:

squid-2.3-STABLE3 with the --enable-snmp compile time option.
mrtg-2.8.11 (yes mrtg is config'd and works)

solaris 7

in squid.conf.

#SNMP Stuff for Squid
#
acl snmppublic snmp_community public
acl thishost src 128.205.0.0/255.255.0.0
acl localhost src 127.0.0.1/255.255.255.255
#
#snmp_access allow snmppublic allowed_hosts
snmp_access allow snmppublic thishost
snmp_access allow snmppublic localhost
snmp_access deny denied

snmp_incoming_address 0.0.0.0
snmp_outgoing_address 0.0.0.0
snmp_port 3401

question:

i'd like to get squid and mrtg working. problem is mrtg's cfgmaker
doesn't understand the syntax of ./cfgmaker community'@'router':3401.

i also stumbled across an mrtg patch at:

http://ircache.nlanr.net/Cache/Statistics/mrtg/mrtg-squid-patch
(NOTE: link was **NOT** in the squid FAQ
http://squid.ircache.net/Doc/FAQ/FAQ-18.html)
 
to patch mrtg. but it doesn't say *HOW* to apply the patch.
i've played with the patch.

here's the error message i get:

ajstack@beavis /opt/src/mrtg/mrtg-2.8.11/run>patch mrtg < mrtg-squid-patch
  Looks like a new-style context diff.
Hunk #1 failed at line 1.
Hunk #2 failed at line 111.
Hunk #3 failed at line 416.
Hunk #4 failed at line 668.
Hunk #5 failed at line 1040.
Hunk #6 failed at line 1408.

add nausem.....

i've also taken the mrtg-squid-snmp.cfg from the link at:

http://ircache.nlanr.net/Cache/Statistics/mrtg/mrtg-squid-snmp.cfg
and made the appropriate changes. here's the error message i get.

SNMPGET: Failed to reach target:
"cacheHttpErrors&cacheHttpErrors:public@137.140.1.88:3401". I tried
multiple times!
Unknown SNMP var cacheHttpHits
Unknown SNMP var cacheHttpHits
SNMPGET: Failed to reach target:
"cacheHttpHits&cacheHttpHits:public@137.140.1.88:3401". I tried multiple
times!

i wouldn't expect this would work b/c i couldn't apply the patch anyways.

the other information i've found is outdated. at least it's for squid-1.x
w/o the snmp interface for it.

i can query the squid snmp interface b/c as the FAQ says, use snmpwalk to
test it.

ajstack@beavis >snmpwalk -p 3401 hostname public .1.3.6.1.4.1.3495.1.1

enterprises.3495.1.1.1.0 = 84
enterprises.3495.1.1.2.0 = 178
enterprises.3495.1.1.3.0 = Timeticks: (9176028) 1 day, 1:29:20.28

so how exactly do i enable mrtg to query squid's snmp port? how do i get
squid and mrtg to work?? (the squid mailing list archive was unvailable at
this time that i wrote this letter)?

-regards
-andrew

#############################
Andrew Stack
UNIX Systems Administrator
State University at New Paltz
Phone: 914.257.3130

GNU/Linux - The choice of a GNU generation.....
#############################
Received on Wed Jan 19 2000 - 15:11:47 MST

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