A java.net.SocketException
"Port already listening" is thrown by TransportMapping.listen()
(or Snmp.listen()
) if that listen()
method has been called before without an intermediate TransportMapping.close()
call. That is, you tried to put the transport mapping into listen mode twice.
See also: Can I use a TransportMapping with two Snmp instances?