Hi, Dave
  I call the trap handler program for the trap.
The mib files for the trap is put into the standard MIB directory for
use.

I can see the routine: netsnmp_sprint_realloc_objid_tree can do the
convertion work, but it's obviously not a good choice for this task, do
you have some suggestion:)

-----Original Message-----
From: [email protected] [mailto:[email protected]] On
Behalf Of ext Dave Shield
Sent: Tuesday, January 19, 2010 4:08 PM
To: Lv, Bo (EXT-Other - CN/Hangzhou)
Cc: [email protected]
Subject: Re: Convert OID to object name

2010/1/19 Lv, Bo (EXT-Other - CN/Hangzhou) <[email protected]>:
>I have a need to convert the caught trap OID into the object name
sending
> the trap:
>
> For example, an agent send a trap (trapSource: .1.2.3.4), to the
snmptrapd,
> the snmptrapd got the trap name is .1.2.3.4
>
> What I need is the name :trapSource for a friendly display.

First question - how are you processing these traps?
Are you calling a trap handler program?  (using "traphandle")
Is snmptrapd logging the trap?
Or have you written your own trap handler routine?

Second question - how are you loading the MIBs that define
these trap OIDs?

Dave

------------------------------------------------------------------------------
Throughout its 18-year history, RSA Conference consistently attracts the
world's best and brightest in the field, creating opportunities for Conference
attendees to learn about information security's most important issues through
interactions with peers, luminaries and emerging and established companies.
http://p.sf.net/sfu/rsaconf-dev2dev
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to