On Wed, 7 Jan 2015 00:40:57 +0000 David wrote:
DH> I ran into an insidious agent (snmpd) hang on Linux that had me stumped
DH> for quite a while. The hang occurred when attempting to walk mib-2 and
DH> always occurred during attempts to walk TCP-MIB::tcpConnTable. At first I
DH> thought this might be related to my build of v5.7.3 'snmpd' (see below),
DH> but I eventually discovered that this was related to the fact that the
DH> system the agent was running on did not have netlink socket diagnostics
DH> configured in the kernel. When this is the case the netlink
DH> (TCPDIAG_GETSOCK) response returns an error; the v5.7.3 version of
DH> agent/mibgroup/mibII/tcpTable.c does not handle this case and the specific
DH> code ends up in an infinite wait. 
DH> 
DH> I've enclosed a patch that illustrates one way of fixing this. This simply
DH> logs an error and then returns from the loop when this case is
DH> encountered. The additional check for a non-zero error code isn't exactly
DH> needed in this case since the original netlink message isn't requesting an
DH> ACK (netlink ACKs are returned as NLMSG_ERROR message types, but with a
DH> zero error code). However, I've left in this check for completeness. I've
DH> also removed a redundant assignment to the 'r' pointer.

David,

Thank you for investigating this issue and sending us a patch. I've applied to
to all active branches which have this code.

DH> * I mentioned that I thought this was originally an issue related to the
DH> build. I still think there are issues with the new 'libnl3' support that
DH> was added in v5.7.3. I'm not an 'autoconf' expert so I won't go into
DH> details about it, but I can describe at a high level what I think is
DH> wrong.

Can you please file a bug with this info for the autoconf issue?

Thanks,
Robert

------------------------------------------------------------------------------
Dive into the World of Parallel Programming. The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Net-snmp-coders mailing list
Net-snmp-coders@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to