> >>>>> On Tue, 9 Nov 2004 14:22:34 +0530 (IST), madanagopal <[EMAIL 
> >>>>> PROTECTED]> said:
> 
> madanagopal> I want to send a v3 trap from agent. So i am using
> madanagopal> send_v2trap(). I have defined v3 parameters using
> madanagopal> trapsess line in snmpd.conf. But i want to send different
> madanagopal> context name for different traps. How to set the context
> madanagopal> name for each trap from agent?
> 
> I don't think that's possible to do at this point (but is a good point).
> 
> 

If it is the case, can i do the following steps to send a v3 trap with 
different contexts:

1. Create a session using snmp_sess_init(session) and fill the v3 
   parameters(securityName,contextName etc.).

2. call setup_engineID(NULL,NULL)

3. open session using snmp_open(&session)

4. create a pdu using snmp_pdu_create(SNMP_MSG_TRAP)

5. add the varbinds to the pdu using snmp_add_var(......)

6. send the pdu using snmp_send(session, pdu)

I want to know whether step 2 is correct. Specifically i want to send the 
trap with the agent's engine ID.

Since i am doing this in my module which is part of the main agent, i will 
remove the trapsink lines from snmpd.conf and have everything read from my 
own conf file. 


-------------------------------------------------------
This SF.Net email is sponsored by: InterSystems CACHE
FREE OODBMS DOWNLOAD - A multidimensional database that combines
robust object and relational technologies, making it a perfect match
for Java, C++,COM, XML, ODBC and JDBC. www.intersystems.com/match8
_______________________________________________
Net-snmp-coders mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to