snmptrapd 5.4 - TrapReceiver problem

"Garry Peirce" <[email protected]>
Newsgroups gmane.network.net-snmp.user
Organization ITS
Message-ID <043601c93482$cbf3b8b0$63db2a10$@edu>
After upgrading to net-snmp 5.4 I'm having problems fixing my trap handlers
and wondering if anyone maybe able to see what is wrong.

Thanks in advance.

 

compiler options: 

./configure --with-perl-modules --enable-embedded-perl --enable-shared
 

For handlers, my snmptrapd.conf files contains:

perl do "/usr/local/share/snmp/handlers/trapHandler.pl";

 

Starting snmptrapd shows:

Loaded the perl snmptrapd handler

NET-SNMP version 5.4.2

 

When using the "all" directive within NetSNMP::TrapReceiver::register I
correctly see the subroutine run.

However I have tried all variants of syntax within the handler to try and
catch an more specific OID and am not having any success.

 

Ex. All below correctly load, but only the 1st is caught and runs the
subroutine (output seen below), all others fail - they do not seem to be
caught as the subroutinge is not run.    Only one of the below is ever
configured at a given time.

NetSNMP::TrapReceiver::register("all", \&traps) || warn "failed to register
our trap handler\n";

NetSNMP::TrapReceiver::register(".1.3.6.1.4.1", \&traps) || warn "failed to
register our trap handler\n";

NetSNMP::TrapReceiver::register(".1.3.6.1.4.1.7737", \&traps) || warn
"failed to register our trap handler\n";

NetSNMP::TrapReceiver::register(".iso.3.6.1.2.1.1.3.0", \&traps) || warn
"failed to register our trap handler\n";

 

 

(IP's removed)

********** PERL RECEIVED A NOTIFICATION:

PDU INFO:

  notificationtype               TRAP

  receivedfrom                   UDP: [x.x.x.x]->[y.y.y.y]:-13281

  version                        1

  errorstatus                    0

  messageid                      0

  community                      public

  transactionid                  1

  errorindex                     0

  requestid                      1146

VARBINDS:

  .iso.3.6.1.2.1.1.3.0           type=67 value=Timeticks: (320443352) 37
days, 2:07:13.52

  .iso.3.6.1.6.3.1.1.4.1.0       type=6  value=OID:
.iso.3.6.1.4.1.7737.7.2.9.3.5.3.4

  .iso.3.6.1.4.1.7737.7.2.9.3.5.2.1.0 type=6  value=OID:
.iso.3.6.1.4.1.7737.7.2.9.2.5.2.1.3.3.1.3.1.2.231

  .iso.3.6.1.4.1.7737.7.2.9.3.5.2.2.0 type=4  value=STRING: "lport
configuration modified"

 

--

Garry Peirce   +1-207-561-3539

Network Analyst,  ITS

University of Maine System

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/

_______________________________________________
Net-snmp-users mailing list
[email protected]
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.