in reply to Re: SNMP Trap Receiver
in thread SNMP Trap Receiver

Thanks for your help Mike. Unfortunately, Net::SNMP seems to do everything except receive traps ;) The low-down is as follows. If you are a SNMP agent running on some device on a network, SNMP allows you to do the following: "Some one's asking me for some info that she knows I have. That's cool, I'll give her said info." That's a SNMP get request followed by the agent's reponse (put, I think). Also, "Damn man! There's something wrong with me!! I'd better send a message out to everyone in my community in case they care. (And I'm likely going to do it on port 162 incidentally.)" That's sending a trap. Net::SNMP is cool with these things.

I'm more interested in making a network management tool. These means I'd be making snmp requests (no problems here) and watching port 162 for traps to come in. Problem is, Net::SNMP doesn't seem to have any way to "sit and look for traps". I guess I could just bite the bullet and do it myself; but it seems like something that should be done by someone on CPAN ;)

Anyways, thanks for reading this long, and likely very inaccurate description of SNMP. It was fun ;)

Replies are listed 'Best First'.
Re: Re: Re: SNMP Trap Receiver
by RMGir (Prior) on Aug 15, 2002 at 11:44 UTC
    Great description, thanks!

    Check out SNMP-4.2.0. It has both SNMP::Session and SNMP::TrapSession, so maybe there's some hope there :)

    If not, check out the other SNMP packages http://search.cpan.org turns up. There's enough of them, ONE of them has to do it...
    --
    Mike