Hello,

I have used send_enterprise_trap_vars in two cases:
1) with net-snmp-5.0.9-2.30E.3
2) with net-snmp-5.1.2-11

In 1) it doesn't work:
the Enterprise field value in the received trap is
1.3.6.1.4.1.8072.3.2.10 whatever enterprise oid I pass to the
send_enterprise_trap_vars API

In 2) it works 
meaning the trap is received with the same enterprise field as the one I
pass to the API


While browsing the list of bugs submitted on net-snmp
I have found that the same problem is already described in the following
bug:
http://sourceforge.net/tracker/index.php?func=detail&aid=769165&group_id
=12694&atid=112694

But its status is still 'open' whereas it seems to be resolved now.

Is it possible to know from which version of net-snmp it has been fixed
?

regards
Sebastien 



-----Original Message-----
From: Dave Shield [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, November 30, 2005 2:26 PM
To: Gonin, Sebastien
Cc: net-snmp-users@lists.sourceforge.net
Subject: Re: send_enterprise_trap_vars and sender Enterprise OID

On Thu, 2005-11-17 at 17:19 +0100, Gonin, Sebastien wrote:

> I use send_enterprise_trap_vars this way:
> 
> send_enterprise_trap_vars ( SNMP_TRAP_ENTERPRISESPECIFIC,
>                           P_TrapId,  G_openCallOID,
>                           openCall_oid_len,L_ptrVarBind);
> 
> where
> SNMP_TRAP_ENTERPRISESPECIFIC = 6
> P_TrapId = 9000344
> G_openCallOID = oid openCall_oid[] = { 1,3,6,1,4,1,11,2,29,2 };


I'm not sure why you're passing "G_openCallOID" rather than using
'openCall_oid' directly, but that looks correct to me.



> - Is it normal to get Enterprise field value set as 
> 1.3.6.1.4.1.8072.3.2.10 instead of enterprises.11.2.29.2  (as I would 
> like it to be) ?

No.
I've just tried using 'send_enterprise_trap_vars' with an explicit OID
parameter, and it sends traps with the specified enterprise field - as
expected.


> - Is there another API (other than send_enterprise_trap_vars)

No - you are using the correct API.
The problem lies elsewhere.


The first thing to check is what the trap generating routines are
actually receiving.  Try running the agent
with the debug flag   "-Dtrap"

What does the agent log when you try to send this trap?





> - And with this potential other API, would it be possible to get rid 
> of  the two parameters below in the traps I receive ?
        [sysUpTime.0 and snmpTrapOID.0]

Those are part of the standard definition of an SNMPv2-style trap, so
would always be included with SNMPv2 (or SNMPv3) notifications, as Wes
says.

But your output seems to indicate that you're using SNMPv1 traps, where
this information is held in the trap header fields.  So I wouldn't
expect to see these as varbinds as well.

Are you generating these traps directly from the main SNMP agent,
or are they coming from an AgentX subagent?   What version of the
Net-SNMP agent code are you using?

Dave


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://ads.osdn.com/?ad_idv37&alloc_id865&op=click
_______________________________________________
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