List Info

Thread: ifHC fallback with snmp v3




ifHC fallback with snmp v3
user name
2006-12-28 14:39:33
In the snmp v2 world, when the ifHC counters fail, mrtg
automagically
switches to snmp v1 and polls the plain if counters.  When
running snmp
v3, you can't fall back to snmp v1 since the credentials
won't work.

My workaround has been in my iftemplate file:
if ($if_ok and $if_snmp_descr !~ /unrouted/ and
$if_snmp_descr !~ /Null/i) { 
my $test_hc =
snmpget($router,$v3opt,'ifHCInOctets.'.$if_index);
if ($test_hc =~ /nosuchinstance/i) {
        $target_lines .= <<LOWSPEED
Target[$target_name]:
ifInOctets$if_ref&ifOutOctets$if_ref:$router_connect
LOWSPEED
;
} else {
        $target_lines .= <<HIGHSPEED
Target[$target_name]: $if_ref:$router_connect
HIGHSPEED
;
}

But, I've recently noticed that the snmp v3 attributes were
being
stripped around line 887 in cfgmaker.

I can fix cfgmaker to always spit out snmp v3 credentials,
but then
there is no ifHC fallback automatically provided by
cfgmaker, and
relying on everyone else to write a custom iftemplate is not
a terribly
supportable solution.  

Should I adjust cfgmaker to do the explicit OID hack for
fallback from
snmp v3, or should I fiddle with the polling process to
trigger the
fallback some other way?  If the latter, what should the
syntax look
like in the .cfg file to signify a fallback?

-- 
Daniel J McDonald, CCIE # 2495, CISSP # 78281, CNX
Austin Energy
http://www.austinenergy.c
om

--
Unsubscribe mailto:mrtg-requestlist.ee.ethz.ch?subject=unsubscribe
Archive     http://lists.ee.ethz.ch/
mrtg
FAQ         http://faq.mrtg.org   
Homepage     http://www.mrtg.org
WebAdmin    http://lists.ee.ethz
.ch/lsg2.cgi

[1]

about | contact  Other archives ( Real Estate discussion Medical topics )