This patch taken from the net-snmp community fixes, an issue related to registration
error recorded in the /var/log/snmpd.log file when snmp is enabled.
The details can be found in the following location
http://sourceforge.net/p/net-snmp/patches/973/
--- a/agent/agent_registry.c 2012-12-18 02:02:56.032682052 -0800
+++ b/agent/agent_registry.c 2012-12-18 02:34:11.953844076 -0800
@@ -532,7 +532,23 @@
if (next && (next->namelen == new_sub->namelen) &&
(next->priority == new_sub->priority)) {
- netsnmp_assert(!"registration != duplicate"); /* always false */
+ if (new_sub->namelen != 1) { /* ignore root OID dups */
+ size_t out_len = 0;
+ size_t buf_len = 0;
+ char *buf = NULL;
+ int buf_overflow = 0;
+
+ netsnmp_sprint_realloc_objid((u_char **) &buf, &buf_len, &out_len,
+ 1, &buf_overflow,
+ new_sub->start_a,
+ new_sub->start_len);
+ snmp_log(LOG_ERR,
+ "duplicate registration: MIB modules %s and %s (oid %s%s).\n",
+ next->label_a, new_sub->label_a,
+ buf ? buf : "",
+ buf_overflow ? " [TRUNCATED]" : "");
+ free(buf);
+ }
return MIB_DUPLICATE_REGISTRATION;
}