Click here to get back home

Receiving snmp traps in perl on Win platform?

 HomeNewsGroups | Search | About
 comp.lang.perl.misc    Post an article   get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
Receiving snmp traps in perl on Win platform? Dirk Van de moortel 06-02-2008
Posted by Dirk Van de moortel on June 2, 2008, 12:47 pm
Please log in for more thread options
{
OOPS, posted this to moderated group perl.cpan.discuss as
well, so it can take a while to get through, if it gets through at all
Otherwise sorry for duplicate posting
}

We need to set up a server 2003 (or a win XP system) to accept
and act upon traps sent out from a storage system. Responding
to various error conditions, this system can be fully configured to
send traps.

I am wondering what must be done on the trap-accepting side.

I am fairly new to SNMP but I managed to install the NET::SNMP
module from
http://search.cpan.org/~dtown/Net-SNMP-5.2.0/lib/Net/SNMP.pm
and use it to interrogate and manipulate a remote SNMP agent (SNMP
service running on a XP-system), i.o.w. all the examples work.
I can do get and sets, and I can send traps to the remote system.
With a little utility like "SNMP Trap Watcher" I see the traps arriving.

Now I would like to create a perl script on the remote system to
listen for traps, and, at this point, to just show them on the console.
The NET::SNMP module seems not to support this.

I have been looking around I do find some examples of trap
listeners, but they all seem to work on unit or Linux only.

The module SNMP
http://search.cpan.org/~hardaker/SNMP-5.0401/SNMP.pm
seems promising, but when I try to install it with ppm, I get
ppm> install SNMP
====================
Install 'SNMP' version 0.0 in ActivePerl 5.8.7.815.
====================
Error: error downloading 'http://theoryx5.uwinnipeg.ca/ppms/x86/Bundle-
NetSNMP.tar.gz': 404 Not Found

Can anyone help me out here?

Tia,
Dirk Vdm


By the way, this might be of interest:
==============================
ppm> rep describe 1
Describing Active Repository 1:
Name: ActiveState Package Repository
Location:
http://ppm.ActiveState.com/PPM/ppmserver-5.8-windows.plex?urn:/PPM/Server/SQL
Type: PPMServer 3.0
ppm>
ppm>
ppm> rep describe 2
Describing Active Repository 2:
Name: uwinnipeg
Location: http://theoryx5.uwinnipeg.ca/ppms/
Type: Webpage
ppm>
ppm>
ppm> search snmp
Searching in Active Repositories
1. Apache-WebSNMP [0.11] Apache-WebSNMP
2. Net-SNMP [5.2] Net-SNMP
3. Net-SNMP [5.2] Object oriented interface to SNMP
4. Net-SNMP-alpha [3.9.6] Net-SNMP-alpha
5. Net-SNMP-HostInfo [0.02] Net-SNMP-HostInfo
6. Net-SNMP-Interfaces [1.2] Net-SNMP-Interfaces
7. POE-Component-SNMP [0.01] POE-Component-SNMP
8. SNMP [0.0]
9. SNMP-BridgeQuery [0.58] SNMP-BridgeQuery
10. SNMP-Effective [1] SNMP-Effective
11. SNMP-MIB-Compiler [0.06] SNMP-MIB-Compiler
12. SNMP-Persist [0.05] SNMP-Persist
13. SNMP-Util [1.8] Snmp modules to perform snmp
set,get,walk,next,walk_hash etc.
ppm>
==============================

Similar ThreadsPosted
Receiving SNMP traps April 5, 2006, 4:45 pm
SNMP module to query net-snmp August 31, 2006, 7:08 am
perl hangs after receiving signal April 1, 2005, 11:09 am
Newbie:PERL SNMP GET May 4, 2006, 6:02 am
Perl SNMP Agent - Receive Requests. May 24, 2006, 11:05 am
Suddenly receiving Premature end January 26, 2006, 2:00 pm
Receiving emails with attachments April 8, 2006, 2:26 pm
Checking the Platform in Perl January 9, 2008, 3:28 pm
Sending/ Receiving SQL arguments to a subroutine February 2, 2005, 8:55 pm
Client Program not Receiving Message from Server January 18, 2008, 12:27 pm

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap