v2 notifications as v1 traps - SNMP

This is a discussion on v2 notifications as v1 traps - SNMP ; When sending v2 notifications as v1 traps, is it correct to set the
enterprise OID to the parent of the trap, the generic type to
enterprise, and the specific type to the last digit of the
notification's oid?
Eg. for ...

v2 notifications as v1 traps

When sending v2 notifications as v1 traps, is it correct to set the
enterprise OID to the parent of the trap, the generic type to
enterprise, and the specific type to the last digit of the
notification's oid?

Re: v2 notifications as v1 traps

Nobody knows? Hmm. Would anyone be able to start and stop a snmpd with
a v1 trap sink registered (probably just with snmptrapd), and let me
know the values of enterpriseOID, specifictype, and generictype? It'd
be very useful, and I'd appreciate it very much.

(I don't have a running net-snmp snmpd or I'd do it myself, obviously.)

Cheers,
-Dan

2008/9/10 dan anderson :
> When sending v2 notifications as v1 traps, is it correct to set the
> enterprise OID to the parent of the trap, the generic type to
> enterprise, and the specific type to the last digit of the
> notification's oid?
>
> Eg. for ucdShutdown, would it be enterpriseOID: ucdavis.ucdTraps,
> generic: 6 (enterprise-specific), specific: 2 (ucdShutdown)?
>
> Cheers,
> -Dan
>

...so you're correctly, IIRC... mostly.
> > When sending v2 notifications as v1 traps, is it correct to set the
> > enterprise OID to the parent of the trap,

If the parent of the *notification* is a "0" value, then use the parent of the parent of the notification, else use the parent of the notification. I suggest you read RFC2576, or its latest update, for details.
> > the generic type to
> > enterprise,

Yes.
> > and the specific type to the last digit of the
> > notification's oid?

That is correct, I think, but note the difference I note above. Basically, SNMPv1 enterprise traps were generally of the form enterprise.trapsId.trapNum, whereas SNMPv3 (SMIv2) notifications (aka SNMPv2 notifications) are recommended to be, and usually are, of the form enterprise.trapsId.0.trapNum for coexistence reasons.