Happy New Year, everyone! I didn't see any responses to this issue over
the last 2 weeks, and I'm still stuck on this problem.

Basically, I am unable to generate any traps from my AgentX agent - I
know from my debug output that my code is being triggered, and I'm
calling the SNMP API to send the trap accordingly, but nothing happens.
The 30-second "built in" heartbeat code (the example) is working just
fine, so I know that traps are being sent and received - i.e. the
destination is set up correctly in the configuration files. (My earlier
response has some of the details.)

So is there a known issue with AgentX and traps? Do I need to configure
the AgentX agent in some special way to get the traps to work? Or is it
more likely something in the way I've defined the trap itself? I used
mib2c to create the actual "trap" code, so it should be correct, as far
as SNMP is concerned. 

Here's the trap stuff from my MIB:

pivot3                  OBJECT IDENTIFIER ::= { enterprises 25148 }

pvt3System MODULE-IDENTITY
    LAST-UPDATED "200712060000Z"
    DESCRIPTION  "MIB for all Pivot3 databank objects"
    REVISION     "200712060000Z"
    DESCRIPTION  "First revision"
    ::= { pivot3 1 }

pvt3SysTraps            OBJECT IDENTIFIER ::= { pvt3System 3 }

    pvt3DatabankDriveStateFailed NOTIFICATION-TYPE
        OBJECTS { name,
                  slot }
        STATUS  current
        DESCRIPTION "This trap is sent when the state of a drive in
                     a databank has changed to FAILED."
        ::= { pvt3SysTraps 7 }

Thanks in advance for any advice - I'm really at my wits end here! As an
experiment later today, I'm going to try to build the 30-second
heartbeat sample trap code as an AgentX agent, and try running that - if
I don't see those traps, then I guess it will confirm my suspicion that
my problem has to do with the fact that I'm trying to send a trap from
an AgentX agent, instead of the main SNMP process. The problem is, I
have to compile my stuff separately from SNMP; I can't add the overhead
of building the entire SNMP product into our build process.

~ Wendy

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
McGowen, Wendy
Sent: Friday, December 14, 2007 2:55 PM
To: net-snmp-users@lists.sourceforge.net
Subject: RE: Enterprise trap question/send_v2trap API call

This is what I have in snmpd.conf:

trapcommunity public
trap2sink localhost public 162
trap2sink 10.1.5.2 public 162
trap2sink 10.2.5.2 public 162
trap2sink 10.1.5.5 public 162

<I don't think the port numbers are necessary anymore . . .>

I'm running snmptrapd on 10.1.5.5, and it is seeing the heartbeat traps
that are being generated by the version of snmpd that I rebuilt this
afternoon (configuration: --with-mib-modules="examples/notification").
But when the same system generates one of my traps, nothing gets sent to
10.1.5.5 (and based on my debug output, I know I'm at least calling
send_v2trap).

I'm beginning to wonder if it's something more to do with the fact that
I'm using AgentX. I turned on the debug in snmpd (the token "traps"),
and I don't see anything logged from netsnmp_send_traps when my trap
code is executed; however, I do see the debug output from the 30 second
"heartbeat" trap. Is there some initialization that needs to be done
before calling send_v2trap if the call is coming from an AgentX agent?

Thanks!

~ wendy

-----Original Message-----
From: Mike Ayers [mailto:[EMAIL PROTECTED] 
Sent: Friday, December 14, 2007 2:11 PM
To: McGowen, Wendy; net-snmp-users@lists.sourceforge.net
Subject: RE: Enterprise trap question/send_v2trap API call

> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On 
> Behalf Of McGowen, Wendy
> Sent: Friday, December 14, 2007 12:04 PM

> Maybe I'm just not seeing the obvious, either in my code or in my MIB,
> but I don't understand why my trap isn't being sent. Any 
> assistance will
> be greatly appreciated!

        How have you configured your destination?


        Thanks,

Mike

------------------------------------------------------------------------
-
SF.Net email is sponsored by:
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services
for just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketp
lace
_______________________________________________
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

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
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