Hi Mostafa, you need to set it in the config file for your agentx(e.g agentx.conf), not in snmpd.conf Regards Anders Wallin
On Thu, Feb 21, 2019 at 1:22 AM Mostafa Kassem <mosta...@danlawinc.com> wrote: > When we restart the snmpd, the agent detects that the snmpd is no longer > running and disconnects, waits 15 seconds and then connects to the snmpd > again. > > AgentX master disconnected us, reconnecting in 15 > > > > I would like to reduce this time to 5 seconds. > > > > Is this time specifieded in agentXPingInterval as described here? > http://www.net-snmp.org/docs/man/snmpd.conf.html > > > > However if I add agentXPingInterval 5 to the snmpd.conf file, I get this > error: > > /var/snmp/snmpd.conf: line 35: Warning: Unknown token:agentXPingInterval. > > > > I found this code in agentx_config.c which leads me to believe that this > value is hardcoded and not set in any configuration file. So changing it > requires editing and recompile of the code. > > > > #ifdef USING_AGENTX_SUBAGENT_MODULE > > /* > > * tokens for master agent > > */ > > if (SUB_AGENT == agent_role) { > > /* > > * set up callbacks to initiate master agent pings for this > session > > */ > > netsnmp_ds_register_config(ASN_INTEGER, > > > netsnmp_ds_get_string(NETSNMP_DS_LIBRARY_ID, > > NETSNMP_DS_LIB_APPTYPE), > > "agentxPingInterval", > > NETSNMP_DS_APPLICATION_ID, > > NETSNMP_DS_AGENT_AGENTX_PING_INTERVAL); > > /* ping and/or reconnect by default every 15 seconds */ > > netsnmp_ds_set_int(NETSNMP_DS_APPLICATION_ID, > > NETSNMP_DS_AGENT_AGENTX_PING_INTERVAL, 15); > > > > } > > #endif /* USING_AGENTX_SUBAGENT_MODULE */ > > > > Thanks, > > > > Mostafa > _______________________________________________ > Net-snmp-users mailing list > Net-snmp-users@lists.sourceforge.net > Please see the following page to unsubscribe or change other options: > https://lists.sourceforge.net/lists/listinfo/net-snmp-users >
_______________________________________________ Net-snmp-users mailing list Net-snmp-users@lists.sourceforge.net Please see the following page to unsubscribe or change other options: https://lists.sourceforge.net/lists/listinfo/net-snmp-users