On 29 January 2013 09:06, Giuseppe Modugno <g.modu...@elettronika.it> wrote:
> I'm interested in sending generic and specific v1 traps.  The Trap-PDU
> always includes an enterprise OID.  Does the standard specify this OID
> for generic traps (coldStart, warmStart...)?

The format of the SNMPv1 trap PDU is defined in RFC 1157, section 4.1.6
This doesn't *explicitly* specify what value the enterprise OID should take,
but there is a strong indication that this should be the value of sysObjectID.

>                                               I noticed Net-SNMP
> (Windows installation) sends coldStart with the following enterprise OID:
>
>    NET-SNMP-MIB::netSnmpAgentOIDs.10

Which is the value of sysObjectID for such an agent.


> Is it correct?

I believe so, yes.   See above.

>  Shouldn't it be a more generic OID, so not related to
> Net-SNMP,

No.
The field is entitled 'enterprise', and is defined as being the
"type of object generating the trap".
   It *is* meant to be enterprise-specific - the whole point of
this field (for generic traps) is that you get some indication
of what type of box/software is sending the trap.


> like SNMPv2-MIB::coldStart ( 1.3.6.1.6.3.1.1.5.1)?

That OID was defined as part of SNMPv2 - which is a good
six years after SNMPv1.
   It would be used when converting a cold start v1 trap into
a v2 (or v3) format notification, but the enterprise-specific OID
would be added as well.  See RFC 3584 for details.



> And what about the enterprise OID to use for specific v1 traps?
>  Can I choose whatever IDs under the private MIB?

No

If the specific trap is defined using SMIv1, then you should use
the value of the ENTERPRISE clause from the MIB definition.
See RFC 1215.

If the specific trap is defined using SMIv2, then you should
use the prefix of the OID of this definition - i.e. everything bar
the final .0.N  (where 'N' is the specific trap number).
Again, see RFC 3584 for details.

Dave

------------------------------------------------------------------------------
Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS,
MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current
with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft
MVPs and experts. ON SALE this month only -- learn more at:
http://p.sf.net/sfu/learnnow-d2d
_______________________________________________
Net-snmp-users mailing list
Net-snmp-users@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Reply via email to