Re: [squid-users] SNMP for Squid

From: Brian E. Seppanen <seppy@dont-contact.us>
Date: Tue, 5 Feb 2002 07:41:57 -0500 (EST)

Here's a page I found helpful.

http://www.squid-cache.org/SNMP/

Remember to load the mibs into mrtg, this should go in your mrtg
configuration.

LoadMIBs: /etc/squid/mib.txt

The mib can be in any arbitrary location depending upon platform, or it
might not even be there if the box doesn't actually run squid. Download
squid if you need a copy of the mib.

Read the configuration help at http://www.mrtg.org for further
information.

Of course you should insure that squid is configured to allow snmp
queries, with the snmppublic acl, and that you allow access

acl TEST src 192.168.1.1/255.255.255.0
acl snmppublic snmp_community public
snmp_access allow snmppublic TEST

HTH

On Tue, 5 Feb 2002, Anton wrote:

> Hi all,
>
> I'm using RH 7.2 and using the Squid Cache: Version 2.4.STABLE1 for my cache
> machine. I'm install MRTG for monitoring my proxy cache hits, and configure
> my squid.conf to open the snmp port for squid 3401. At my mrtg config line i
> just put target to monitoring Cache Hits and Cache Sever below:
>
> #Cache Hits Target
> ......cut
> Target[proxy-hits]:
> cacheHttpHits&cacheClientHttpRequests:public@localhost:3401
> ......cut
>
> #Cache Server Target
> ...cut
> Target[proxy-serverkbinout]:
> cacheServerInKb&cacheServerOutKb:public@localhost:3401
> ....cut
>
> The target just work for Cache Server, but for Cache Hits i found the error
> below :
>
> ------cut
> sh-2.05# ./mrtg squid.cfg
> SNMP Error:
> Received SNMP response with error code
> error status: noSuchName
> index 2 (OID: 1.3.6.1.4.1.3495.1.5.2.1.2)
> SNMPv1_Session (remote host: "localhost" [127.0.0.1].3401)
> community: "public"
> request ID: 539650052
> PDU bufsize: 8000 bytes
> timeout: 2s
> retries: 5
> backoff: 1)
> at /SNMP_util.pm line 450
> SNMPGET Problem for cacheHttpHits cacheClientHttpRequests on
> public@localhost:3401
> at ./mrtg line 1916
> SNMPGET: Failed to reach target:
> "cacheHttpHits&cacheClientHttpRequests:public@localhost:3401". I tried
> multiple times! public@localhost:3401
> sh-2.05#
> ------cut
>
> Any comments??
>
>
> Anton
>
>
> _________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.com address at http://mail.yahoo.com
>

Brian Seppanen
seppy@chartermi.net
906-228-4226 ext 23
Area 54: The Secret Government Disco Labs in Provo Utah
Received on Tue Feb 05 2002 - 05:39:54 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 17:06:10 MST