[SNMP4J] NullPointerException
Alex Chen
achen at packetmotion.com
Thu Apr 20 02:43:24 CEST 2006
Sorry, the listener message of the failure case should be
Listening on 0.0.0.0/47162
It was a cut and paste error.
-----Original Message-----
From: snmp4j-bounces at agentpp.org [mailto:snmp4j-bounces at agentpp.org] On
Behalf Of Alex Chen
Sent: Wednesday, April 19, 2006 5:29 PM
To: snmp4j at agentpp.org
Subject: [SNMP4J] NullPointerException
I am using the latest 1.7 release of SNMP4J.
I try to run two instances of the program
org.snmp4j.tools.console.SnmpRequest
on two different machines, one as a trap listener and the other a trap
sender.
Here are the argument lists of the two.
Listener:
-a MD5 -A myPassword -Ol 0.0.0.0/47162
Sender:
-a MD5 -A myPassword -Ca 172.16.3.36 -Cg 6 -Cs 1234 -Ce 1234 -p TRAP
172.16.1.50/47162
I got the correct messages on both.
Listener:
Listening on 0.0.0.0/47162
TRAP[reqestID=1881841637, errorStatus=0, errorIndex=0,
VBS[1.3.6.1.2.1.1.3.0 = 0:00:00.00; 1.3.6.1.6.3.1.1.4.1.0 =
1.3.6.1.6.3.1.1.5.1]]
Sender:
TRAP sent successfully
If I set the transport to TCP, i. e.
Listener:
-a MD5 -A myPassword -Ol tcp:0.0.0.0/47162
Sender:
-a MD5 -A myPassword -Ca 172.16.3.36 -Cg 6 -Cs 1234 -Ce 1234 -p TRAP
tcp:172.16.1.50/47162
I got the following messages:
Listener:
Listening on 0.0.0.0/262
TRAP[reqestID=1813617928, errorStatus=0, errorIndex=0,
VBS[1.3.6.1.2.1.1.3.0 = 0:00:00.00; 1.3.6.1.6.3.1.1.4.1.0 =
1.3.6.1.6.3.1.1.5.1]]
Sender:
java.lang.NullPointerException
at
org.snmp4j.transport.DefaultTcpTransportMapping.close(DefaultTcpTranspor
tMapping.java:185)
at org.snmp4j.Snmp.close(Snmp.java:429)
at
org.snmp4j.tools.console.SnmpRequest.send(SnmpRequest.java:390)
at
org.snmp4j.tools.console.SnmpRequest.main(SnmpRequest.java:1141)
The listener is a Linux machine running RedHat 9 and the sender machine
is a Windows XP box.
_______________________________________________
SNMP4J mailing list
SNMP4J at agentpp.org
http://lists.agentpp.org/mailman/listinfo/snmp4j
More information about the SNMP4J
mailing list