Re: ucd-snmp:why not send trap by send_v2trap()
"Dave Shield" <[email protected]>
| Newsgroups | gmane.network.net-snmp.user,gmane.linux.uclinux.devel |
|---|---|
| Message-ID | <[email protected]> |
On 12/09/2007, ye_cl <[email protected]> wrote: > In my snmpd agent, the trap2sink ip address will be changed sometimes,but in > my embedded uClinux,the filesystem is read-only(romfs), so I can't change > the trap2sink directive in file "snmpd.conf" which is in filesystem. > Now,I delete all lines of trap2sink in snmpd.conf, and use the ucd-snmp API > functions to implement it,but by using API functions, I find the UDP trap > packages can't be sent out. The 'send_v2trap' and similar API calls rely on the MIB settings configured by the 'trap2sink' (and related) directives. If those MIB entries are not present, then the agent will not send any traps. If you can't change the snmpd.conf file, then you could try setting up equivalent MIB entries using "snmpset" requests. I'd start by configuring the agent with a single "trap2sink" directive, and walk the tables: SNMP-NOTIFICATION-MIB::snmpNotifyTable SNMP-TARGET-MIB::snmpTargetAddrTable SNMP-TARGET-MIB::snmpTargetParamsTable That will show you the sort of settings that are needed. Then restart the agent using a configuration *without* the "trap2sink" directive, and try to recreate the same settings in these three tables using "snmpset". Dave ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Net-snmp-users mailing list [email protected] Please see the following page to unsubscribe or change other options: https://lists.sourceforge.net/lists/listinfo/net-snmp-users