On 4 March 2010 10:48, maxim maxim <[email protected]> wrote:
> if i want to send v1 trap from notification.c(see in examples), does
> it mean that i don't have to use snmp_varlist_add_variable() with
> ASN_OBJECT_ID?, i just need to fill netsnmp_variable_list only with
> varbinds like integer or string

It depends on the payload for that particular trap.
If the trap definition includes a list of additional objects,
then you need to add these to the payload, using
      snmp_varlist_add_variable()

These may be integer-based varbinds, strings or OID values.
It all depends on the trap definition.


> the trap name is not in list of varbinds, isn't it?

Correct.
With SNMP v1, the trap is identified by the 'generic', 'specific'
pair or integers plus the enterprise OID.   Which are parameters
to (some of) the agent trap API calls.

With SNMPv2, these three values were pulled together into a
single OID, which was included as part of the payload list.

You can specify the notification in either form.
The agent will take care of convering it as required.

Dave

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to