get_notify_id() method with a notify, not a trap

Lukasz Szczepankowski lukasz____nnu.com
Tue Nov 27 23:00:24 CET 2001


Hello,
following you will find the command that I executed:

[lukasz at aveta lukasz]$ snmpInform localhost -p162     
SNMP++ Trap to localhost SNMPV1 Community=public
Oid = 1.3.6.1.4.1.11.2.16.2
Value = This is the response.

This is what I received from receive_trap:
[root at aveta lukasz]# receive_trap 162
Trying to register for traps on port 162.
Waiting for traps/informs...
reason: -7
msg: SNMP++: Received SNMP Notification (trap or inform)
from: 127.0.0.1/4372
ID:  
Type:166
Oid: 1.3.6.1.2.1.1.3.0
Val: 201 days, 3:35:59.63
Oid: 1.3.6.1.6.3.1.1.4.1.0
Val: 1.3.6.1.6.3.1.1.5.1
Oid: 1.3.6.1.4.1.11.2.16.2
Val: SNMP++ Trap Send Test
pdu type: 166
sending response to inform: 


As you can see, the ID field is blank.  The inform oid is sent as part of
the inform, but the get_notify_id() call does not seem to return the oid.
You have to scan all vbs in the pdu to retrieve this information.

Is this the correct behavior?

Thanks,

Lukasz Szczepankowski



> -----Original Message-----
> From: Jochen Katz [mailto:katz____agentpp.com]
> Sent: Tuesday, November 27, 2001 3:42 PM
> To: Lukasz Szczepankowski
> Cc: 'agentpp-dl____agentpp.com'
> Subject: Re: get_notify_id() method with a notify, not a trap
> 
> 
> Hi,
> 
> > When I receive a trap, I can use the get_notify_id() method 
> to get the oid
> > of the trap.  However, I can't seem to get this method to 
> work when I
> > receive a notify.  The oid that it returns is blank.  I 
> have verified this
> > with both my trap receive daemon as well as the 
> receive_trap example.
> > 
> > Are informs supposed to support the get_notify_id() method?
> 
> If I send a Inform using the snmpInform example, the receive_trap
> example shows the id that was specified in the command line. 
> So informs
> support the get_notify_id().
> 
> Kind regards,
>   Jochen
> 



More information about the AGENTPP mailing list