|
I
need to support a SNMP client that does not understand the SMIv2
NOTIFICATION-TYPE. I've loaded the MIB in and it does not recognize it
as an event it can register but it does handle TRAP-TYPE. I assumed
that I was doing something wrong and needed to have MIBS with both the
NOTIFICATION-TYPE and TRAP-TYPE but based on your explanation that is
clearly not the case. Should I create a separate MIB for that client
that uses TRAP-TYPE with the same OID as the NOTIFICATION-TYPE?
Thank you for the clear and detailed answers. smilint already flagged that the parent of the notification object needed to be zero but it was nice for you to mention that since it's an easy mistake. Scott -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of Dave Shield Sent: Friday, September 04, 2009 1:59 AM 2009/9/4 Scott Grumm <[email protected]>: > I am trying to send both v1 and v2c traps and am having problems figuring > out the right way to do it. > > Originally I thought that I should have two MIBs, one with a TRAP-TYPE > definition and one with a NOTIFICATION-TYPE definition. No. The version of SMI used to define a MIB is completely seperate from the version of SNMP used to send requests. You should define *one* notification (using SMIv2 and NOTIFICATION-TYPE). This notification can then be sent via any of the three versions of SNMP. (as either an unacknowledged trap, or an achnowleged inform request) > Do I have one MIB that uses the TRAP-TYPE definition and assume that a v2c > client would do the appropriate conversion? Close but not quite. You should define a single NOTIFICATION-TYPE object, and allow the agent to convert back down for SNMPv1. Just make sure that the parent of the notification object has the value '0' (See the project MIBs for details). > The FAQ: Can I use SNMPv1 requests with a SNMPv2 MIB (or vice versa)? > (http://net-snmp.sourceforge.net/wiki/index.php/FAQ:General_15) > is not clear if it applies to traps or not. Yes - it applies to *ALL* SNMP requests. There's nothing special about notifications. > What is the best way to do this? My main concern is getting the OID in the > trap to match the MIB. See above. Dave |
------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july
_______________________________________________ Net-snmp-coders mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
