On tis, 2007-03-13 at 12:36 +0000, Joao Miguel Ferreira wrote: > Hello all, > > I've posted this question on the users list, but did not find the most > correct approach to do this. My problem is simple: my application needs > to request snmpd to send a trap. > > Is there an API to ask the agent to send a trap (I do not mean an API to > send the trap... I mean an API to ask the agent to send it.... or to ask > the agent to execute some C code in which I would program my trap > sending...)
You could use AgentX (RFC 2741) for this - if you only wish to send traps you should get away with a rudimentary implementation supporting only Open, Close, Notify, Ping and Response. > I guess asking the agent to send the trap would avoid me having to go > through all the trapsinks/informsynks in snmpd.conf myself... much more > eficient. Possibly. You'd have to implement some other API somehow. > On the users list someone said I could alter the agent's code to open a > socket and add it to the select() call, and so on. It will work, but > isn't there be a better approach for this ? As I said above AgentX sounds like the thing for you. /MF ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys-and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Net-snmp-coders mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
