Re: [squid-users] Squid 3.1 with MRTG, Not able to get Graphs- squid upgraded to 3.1.8 ( Resolved at last)
Hi List, At last I could get the MRTG running with squid 3.1.8, though it took much time. Will be writing a howto soon regarding how to set up mrtg on FreeBSD. It was the SNMP_util.pm gave all the trouble as the port maintainers did some changes of merging. Those who are breaking head with mrtg kindly have p5-SNMP_Session port to be installed additionally and save the time. Hope that may help someone in future. Thank you so much to those took their valuable time to reply to my silly doubts and cleared and guided me. Regards Babs On 10/4/10, Babu Chaliyath wrote: >> It's well worth upgrading to 3.1.8. Many of the 3.1 betas had broken >> SNMP. >> >> Also check that the squid.mib being loaded came from the 3.1 install. >> >> We now have a full map of what the OID are and what versions they work >> for. You may find this useful: >> http://wiki.squid-cache.org/Features/Snmp#Squid_OIDs >> >> >> Amos >> -- >> Please be using >>Current Stable Squid 2.7.STABLE9 or 3.1.8 >>Beta testers wanted for 3.2.0.2 >> > > Hi List, > As suggested by Amos, I have upgraded the squid box to 3.1.8 and > everything is working fine except the graph part with mrtg. > mrtg version :mrtg-2.16.4 > > My mrtg.cfg is as below > > LoadMIBs: /usr/local/etc/mrtg/squid.mib > EnableIPv6: no > WorkDir: /usr/local/www/apache22/data > Options[_]: bits,growright > > Target[proxy-hit]: cacheHttpHits&cacheServerRequests:pub...@127.0.0.1:3401 > MaxBytes[proxy-hit]: 10 > Title[proxy-hit]: HTTP Hits > Suppress[proxy-hit]: y > LegendI[proxy-hit]: HTTP hits > LegendO[proxy-hit]: HTTP requests > Legend1[proxy-hit]: HTTP hits > Legend2[proxy-hit]: HTTP requests > YLegend[proxy-hit]: perminute > ShortLegend[proxy-hit]: req/min > Options[proxy-hit]: nopercent, perminute, dorelpercent, unknaszero, > growright, pngdate > #PNGTitle[proxy-hit]: Proxy Hits > > Target[proxy-srvkbinout]: > cacheServerInKb&cacheServerOutKb:pub...@127.0.0.1:3401 > MaxBytes[proxy-srvkbinout]: 76800 > Title[proxy-srvkbinout]: Cache Server Traffic In/Out > Suppress[proxy-srvkbinout]: y > LegendI[proxy-srvkbinout]: Traffic In > LegendO[proxy-srvkbinout]: Traffic Out > Legend1[proxy-srvkbinout]: Traffic In > Legend2[proxy-srvkbinout]: Traffic Out > YLegend[proxy-srvkbinout]: per minute > ShortLegend[proxy-srvkbinout]: b/min > kMG[proxy-srvkbinout]: k,M,G,T > kilo[proxy-srvkbinout]: 1024 > Options[proxy-srvkbinout]: nopercent, perminute, unknaszero, growright, > pngdate > > I have verified that squid snmp is working through the following command > > #snmpget -On -m /usr/local/etc/mrtg/squid.mib -v 2c -c public > 127.0.0.1:3401 cacheHttpHits cacheServerRequests cacheServerInKb > cacheServerOutKb cacheUptime CacheSoftware cacheVersionId > > This gives me results without any errors so snmp part of squid is > working fine I think > Now when I run mrtg I could see the following errors in mrtg.log file > > 010-10-04 12:37:33 -- Started mrtg with config > '/usr/local/etc/mrtg/mrtg.cfg' > 2010-10-04 12:37:33 -- Unknown SNMP var cacheHttpHits > at /usr/local/bin/mrtg line 2242 > 2010-10-04 12:37:33 -- Unknown SNMP var cacheServerRequests > at /usr/local/bin/mrtg line 2242 > 2010-10-04 12:37:33 -- Unknown SNMP var cacheUptime > at /usr/local/bin/mrtg line 2242 > 2010-10-04 12:37:33 -- Unknown SNMP var cacheSoftware > at /usr/local/bin/mrtg line 2242 > 2010-10-04 12:37:33 -- Unknown SNMP var cacheVersionId > at /usr/local/bin/mrtg line 2242 > 2010-10-04 12:37:33 -- Use of uninitialized value $ret[-2] in > concatenation (.) or string at /usr/local/bin/mrtg line 2261. > 2010-10-04 12:37:33 -- Use of uninitialized value $ret[-1] in > concatenation (.) or string at /usr/local/bin/mrtg line 2261. > 2010-10-04 12:37:33 -- Unknown SNMP var cacheServerInKb > at /usr/local/bin/mrtg line 2242 > 2010-10-04 12:37:33 -- Unknown SNMP var cacheServerOutKb > at /usr/local/bin/mrtg line 2242 > 2010-10-04 12:37:33 -- Unknown SNMP var cacheUptime > at /usr/local/bin/mrtg line 2242 > 2010-10-04 12:37:33 -- Unknown SNMP var cacheSoftware > at /usr/local/bin/mrtg line 2242 > 2010-10-04 12:37:33 -- Unknown SNMP var cacheVersionId > at /usr/local/bin/mrtg line 2242 > 2010-10-04 12:37:33 -- Use of uninitialized value $ret[-2] in > concatenation (.) or string at /usr/local/bin/mrtg line 2261. > 2010-10-04 12:37:33 -- Use of uninitialized value $ret[-1] in > concatenation (.) or string at /usr/local/bin/mrtg line 2261. > 2010-10-04 12:37:33 -- 2010-10-04 12:37:33: ERROR: > Target[proxy-hit][_IN_] ' $target->[0]{$mode} ' did not eval into > defined data > 2010-10-04 12:37:33 -- 2010-10-04 12:37:33: ERROR: > Target[proxy-hit][_OUT_] ' $target->[0]{$mode} ' did not eval into > defined data > 2010-10-04 12:37:33 -- 2010-10-04 12:37:33: ERROR: > Target[proxy-srvkbinout][_IN_] ' $target->[1]{$mode} ' did not eval > into defined data > 2010-10-04 12:37:33 -- 2010-10-04 12:37:33: ERROR: > Target[proxy-srvkbinout][_OUT_] ' $target->[1]{$mode} ' did not eval > into defined data > > All I could make out from these
Re: [squid-users] Squid 3.1 with MRTG, Not able to get Graphs- squid upgraded to 3.1.8
> It's well worth upgrading to 3.1.8. Many of the 3.1 betas had broken SNMP. > > Also check that the squid.mib being loaded came from the 3.1 install. > > We now have a full map of what the OID are and what versions they work > for. You may find this useful: > http://wiki.squid-cache.org/Features/Snmp#Squid_OIDs > > > Amos > -- > Please be using >Current Stable Squid 2.7.STABLE9 or 3.1.8 >Beta testers wanted for 3.2.0.2 > Hi List, As suggested by Amos, I have upgraded the squid box to 3.1.8 and everything is working fine except the graph part with mrtg. mrtg version :mrtg-2.16.4 My mrtg.cfg is as below LoadMIBs: /usr/local/etc/mrtg/squid.mib EnableIPv6: no WorkDir: /usr/local/www/apache22/data Options[_]: bits,growright Target[proxy-hit]: cacheHttpHits&cacheServerRequests:pub...@127.0.0.1:3401 MaxBytes[proxy-hit]: 10 Title[proxy-hit]: HTTP Hits Suppress[proxy-hit]: y LegendI[proxy-hit]: HTTP hits LegendO[proxy-hit]: HTTP requests Legend1[proxy-hit]: HTTP hits Legend2[proxy-hit]: HTTP requests YLegend[proxy-hit]: perminute ShortLegend[proxy-hit]: req/min Options[proxy-hit]: nopercent, perminute, dorelpercent, unknaszero, growright, pngdate #PNGTitle[proxy-hit]: Proxy Hits Target[proxy-srvkbinout]: cacheServerInKb&cacheServerOutKb:pub...@127.0.0.1:3401 MaxBytes[proxy-srvkbinout]: 76800 Title[proxy-srvkbinout]: Cache Server Traffic In/Out Suppress[proxy-srvkbinout]: y LegendI[proxy-srvkbinout]: Traffic In LegendO[proxy-srvkbinout]: Traffic Out Legend1[proxy-srvkbinout]: Traffic In Legend2[proxy-srvkbinout]: Traffic Out YLegend[proxy-srvkbinout]: per minute ShortLegend[proxy-srvkbinout]: b/min kMG[proxy-srvkbinout]: k,M,G,T kilo[proxy-srvkbinout]: 1024 Options[proxy-srvkbinout]: nopercent, perminute, unknaszero, growright, pngdate I have verified that squid snmp is working through the following command #snmpget -On -m /usr/local/etc/mrtg/squid.mib -v 2c -c public 127.0.0.1:3401 cacheHttpHits cacheServerRequests cacheServerInKb cacheServerOutKb cacheUptime CacheSoftware cacheVersionId This gives me results without any errors so snmp part of squid is working fine I think Now when I run mrtg I could see the following errors in mrtg.log file 010-10-04 12:37:33 -- Started mrtg with config '/usr/local/etc/mrtg/mrtg.cfg' 2010-10-04 12:37:33 -- Unknown SNMP var cacheHttpHits at /usr/local/bin/mrtg line 2242 2010-10-04 12:37:33 -- Unknown SNMP var cacheServerRequests at /usr/local/bin/mrtg line 2242 2010-10-04 12:37:33 -- Unknown SNMP var cacheUptime at /usr/local/bin/mrtg line 2242 2010-10-04 12:37:33 -- Unknown SNMP var cacheSoftware at /usr/local/bin/mrtg line 2242 2010-10-04 12:37:33 -- Unknown SNMP var cacheVersionId at /usr/local/bin/mrtg line 2242 2010-10-04 12:37:33 -- Use of uninitialized value $ret[-2] in concatenation (.) or string at /usr/local/bin/mrtg line 2261. 2010-10-04 12:37:33 -- Use of uninitialized value $ret[-1] in concatenation (.) or string at /usr/local/bin/mrtg line 2261. 2010-10-04 12:37:33 -- Unknown SNMP var cacheServerInKb at /usr/local/bin/mrtg line 2242 2010-10-04 12:37:33 -- Unknown SNMP var cacheServerOutKb at /usr/local/bin/mrtg line 2242 2010-10-04 12:37:33 -- Unknown SNMP var cacheUptime at /usr/local/bin/mrtg line 2242 2010-10-04 12:37:33 -- Unknown SNMP var cacheSoftware at /usr/local/bin/mrtg line 2242 2010-10-04 12:37:33 -- Unknown SNMP var cacheVersionId at /usr/local/bin/mrtg line 2242 2010-10-04 12:37:33 -- Use of uninitialized value $ret[-2] in concatenation (.) or string at /usr/local/bin/mrtg line 2261. 2010-10-04 12:37:33 -- Use of uninitialized value $ret[-1] in concatenation (.) or string at /usr/local/bin/mrtg line 2261. 2010-10-04 12:37:33 -- 2010-10-04 12:37:33: ERROR: Target[proxy-hit][_IN_] ' $target->[0]{$mode} ' did not eval into defined data 2010-10-04 12:37:33 -- 2010-10-04 12:37:33: ERROR: Target[proxy-hit][_OUT_] ' $target->[0]{$mode} ' did not eval into defined data 2010-10-04 12:37:33 -- 2010-10-04 12:37:33: ERROR: Target[proxy-srvkbinout][_IN_] ' $target->[1]{$mode} ' did not eval into defined data 2010-10-04 12:37:33 -- 2010-10-04 12:37:33: ERROR: Target[proxy-srvkbinout][_OUT_] ' $target->[1]{$mode} ' did not eval into defined data All I could make out from these error was mrtg not reading squid.mib file. Am I right? Now I am stuck and I suspect a broken mrtg? or did I go wrong somewhere? Do kindly let me know what went wrong and how to proceed further. Thanx in advance Babs
Re: [squid-users] Squid 3.1 with MRTG, Not able to get Graphs
On 09/09/10 21:38, Babu Chaliyath wrote: 2010/9/9 Henrik Nordström: tor 2010-09-09 klockan 11:36 +0530 skrev Babu Chaliyath: Hi List, I am trying to get mrtg graphing of my squid box running freebsd 7.2 with squid 3.1.0.13, I was able to get the mrtg while running 2.6 version of squid, but once moved to 3.1 version, I am not able to get the mrtg graph at all, I would greatly appreciate if any suggestions/clues what might have gone wrong on my mrtg setup. I did not see any reference to the Squid MIB from your mrtg config. Regards Henrik Ooops! I missed "LoadMIBs: /usr/local/etc/mrtg/squid.mib" line while pasting it in my mail, yes it is there in my mrtg.cfg btw mib.txt file is renamed as squid.mib. Thanx for that quick reply Regards Babs It's well worth upgrading to 3.1.8. Many of the 3.1 betas had broken SNMP. Also check that the squid.mib being loaded came from the 3.1 install. We now have a full map of what the OID are and what versions they work for. You may find this useful: http://wiki.squid-cache.org/Features/Snmp#Squid_OIDs Amos -- Please be using Current Stable Squid 2.7.STABLE9 or 3.1.8 Beta testers wanted for 3.2.0.2
Re: [squid-users] Squid 3.1 with MRTG, Not able to get Graphs
2010/9/9 Henrik Nordström : > tor 2010-09-09 klockan 11:36 +0530 skrev Babu Chaliyath: >> Hi List, >> I am trying to get mrtg graphing of my squid box running freebsd 7.2 >> with squid 3.1.0.13, I was able to get the mrtg while running 2.6 >> version of squid, but once moved to 3.1 version, I am not able to get >> the mrtg graph at all, I would greatly appreciate if any >> suggestions/clues what might have gone wrong on my mrtg setup. > > I did not see any reference to the Squid MIB from your mrtg config. > > Regards > Henrik > > Ooops! I missed "LoadMIBs: /usr/local/etc/mrtg/squid.mib" line while pasting it in my mail, yes it is there in my mrtg.cfg btw mib.txt file is renamed as squid.mib. Thanx for that quick reply Regards Babs
Re: [squid-users] Squid 3.1 with MRTG, Not able to get Graphs
tor 2010-09-09 klockan 11:36 +0530 skrev Babu Chaliyath: > Hi List, > I am trying to get mrtg graphing of my squid box running freebsd 7.2 > with squid 3.1.0.13, I was able to get the mrtg while running 2.6 > version of squid, but once moved to 3.1 version, I am not able to get > the mrtg graph at all, I would greatly appreciate if any > suggestions/clues what might have gone wrong on my mrtg setup. I did not see any reference to the Squid MIB from your mrtg config. Regards Henrik
[squid-users] Squid 3.1 with MRTG, Not able to get Graphs
Hi List, I am trying to get mrtg graphing of my squid box running freebsd 7.2 with squid 3.1.0.13, I was able to get the mrtg while running 2.6 version of squid, but once moved to 3.1 version, I am not able to get the mrtg graph at all, I would greatly appreciate if any suggestions/clues what might have gone wrong on my mrtg setup. System details as follows OS verion FreeBSD 7.2 Squid version 3.1.0.13 mrtg version 2.16.2 my mrtg.cfg ##MRTG Configuration file ### WorkDir: /home/www/mrtg/ Options[_]: bits,growright logFormat: rrdtool Target[proxy-hit]: cacheHttpHits&cacheServerRequests:pub...@localhost:3401 MaxBytes[proxy-hit]: 10 Title[proxy-hit]: HTTP Hits Suppress[proxy-hit]: y LegendI[proxy-hit]: HTTP hits LegendO[proxy-hit]: HTTP requests Legend1[proxy-hit]: HTTP hits Legend2[proxy-hit]: HTTP requests YLegend[proxy-hit]: perminute ShortLegend[proxy-hit]: req/min Options[proxy-hit]: nopercent, perminute, dorelpercent, unknaszero, growright, pngdate PNGTitle[proxy-hit]: Proxy Hits Target[proxy-srvkbinout]: cacheServerInKb&cacheServerOutKb:pub...@localhost:3401 MaxBytes[proxy-srvkbinout]: 76800 Title[proxy-srvkbinout]: Cache Server Traffic In/Out Suppress[proxy-srvkbinout]: y LegendI[proxy-srvkbinout]: Traffic In LegendO[proxy-srvkbinout]: Traffic Out Legend1[proxy-srvkbinout]: Traffic In Legend2[proxy-srvkbinout]: Traffic Out YLegend[proxy-srvkbinout]: per minute ShortLegend[proxy-srvkbinout]: b/min kMG[proxy-srvkbinout]: k,M,G,T kilo[proxy-srvkbinout]: 1024 Options[proxy-srvkbinout]: nopercent, perminute, unknaszero, growright, pngdate PNGTitle[proxy-srvkbinout]: Proxy Traffic In/Out ## End of MRTG Configuration ### Kindly note that I can successfully run the following command too #snmpwalk -m /usr/local/etc/squid/mib.txt -v2c -Cc -c public localhost:3401 .1.3.6.1.4.1.3495.1.1 SQUID-MIB::cacheSysVMsize.0 = INTEGER: 16348 SQUID-MIB::cacheSysStorage.0 = INTEGER: 7535652 SQUID-MIB::cacheUptime.0 = Timeticks: (162270170) 18 days, 18:45:01.70 Pls let me know how can I get the graphing started Thanx & Regards Babs