On Mon, 2013-08-26 at 21:04 -0300, Leonardo Chiquitto wrote:
> Hi,
> 
> 
> This is about http://sourceforge.net/p/net-snmp/bugs/2478/. I've been
> doing some tests with the original fix and the follow-up patch and I'd
> like to ask your help to confirm if I've found a real problem or not.
> 
> 
> After applying only commit 78dac6e3 on top of 5.7.2, I'm getting what
> I suppose is the correct value of snmpTargetAddrTimeout (100cs or 1s):
> 
> 
> $ snmpwalk -v2c -c public localhost snmpTargetAddr
> (...)
> SNMP-TARGET-MIB::snmpTargetAddrTimeout.'internal0' = INTEGER: 100
> 
> SNMP-TARGET-MIB::snmpTargetAddrRetryCount.'internal0' = INTEGER: 5
> (...)
> 
> 
> If I apply 78dac6e3 and 39030305, I'm getting the old (wrong) Timeout
> value
> again:
> 
> 
> $ snmpwalk -v2c -c public localhost snmpTargetAddr
> (...)
> SNMP-TARGET-MIB::snmpTargetAddrTimeout.'internal0' = INTEGER: 1000
> SNMP-TARGET-MIB::snmpTargetAddrRetryCount.'internal0' = INTEGER: 5
> (...)
> 
> 
> Even though the returned value differs, it's always respecting the
> default
> 1s timeout before retrying. Any idea on what could be wrong in the
> second
> patch?

I think I have an idea - could you please try the attached patch?


/MF

> Thanks,
> Leonardo
> ------------------------------------------------------------------------------
> Introducing Performance Central, a new site from SourceForge and 
> AppDynamics. Performance Central is your source for news, insights, 
> analysis and resources for efficient Application Performance Management. 
> Visit us today!
> http://pubads.g.doubleclick.net/gampad/clk?id=48897511&iu=/4140/ostg.clktrk
> _______________________________________________ Net-snmp-coders mailing list 
> Net-snmp-coders@lists.sourceforge.net 
> https://lists.sourceforge.net/lists/listinfo/net-snmp-coders


diff --git a/agent/mibgroup/notification/snmpNotifyTable.c b/agent/mibgroup/notification/snmpNotifyTable.c
index a1ed680..5c369d7 100644
--- a/agent/mibgroup/notification/snmpNotifyTable.c
+++ b/agent/mibgroup/notification/snmpNotifyTable.c
@@ -333,7 +333,7 @@ notifyTable_register_notifications(int major, int minor,
     ptr->tAddressLen = t->remote_length;
     ptr->tAddress = t->remote;
 
-    ptr->timeout = ss->timeout / 1000;
+    ptr->timeout = ss->timeout / 10000;
     ptr->retryCount = ss->retries;
     SNMP_FREE(ptr->tagList);
     ptr->tagList = strdup(buf); /* strdup ok since buf contains 'internal%d' */
------------------------------------------------------------------------------
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
_______________________________________________
Net-snmp-coders mailing list
Net-snmp-coders@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to