[SNMP4J] snmp4j and UdpPortUnreachable

Frank Fock fock at agentpp.com
Sat Feb 16 00:57:54 CET 2013


Hi,

ICMP is not UDP. Which peer should send what message and which peer 
closes the socket.
I am confused...

Best regards,
Frank

Am 16.02.2013 00:52, schrieb vitz me:
>   Hello,
> Thanks for the reply. I probably used wrong wording here (as I have seen something like UdpPortUnreachable exception in Java).. But still there should be an ICMP port unreachable message (type 3, code 3) in case if UDP port is closed (and not filtered; RFC 792 if I'm not mistaken)...which in turn should make it possible to process the message and not wait for the timeouts.. Please, correct me if I'm wrong...
> Thanks..
>
>
> Пятница, 15 февраля 2013, 23:47 +01:00 от Frank Fock <fock at agentpp.com>:
>> Hi,
>>
>> It seems that you mix up connection oriented communication (TCP) with
>> connection less (UDP).
>> With UDP you will never know if a target port is reachable or if the
>> application listening on the
>> target port is not responding. In both cases you simply wait forever for
>> a response (=timeout).
>>
>> Thus, there is no need to change SNMP4J.
>>
>> Best regards,
>> Frank
>>
>>
>> Am 15.02.2013 16:30, schrieb vitz me:
>>> I'm a beginner with Java and SNMP and trying to perform simple get requests. I faced an issue when the connection timeouts seem to still have an effect, even though the port specified for SNMP connection is closed on the target host.
>>> Is it possible to somehow process the UdpPortUnreachable (exception) within snmp4j? So that if the port is closed the timeout setting would not have any effect. Or what could be a way for getting around this problem?
>>> The only way I could think of was trying to check the port using Java sockets before even trying to send SNMP requests..
>>> Thanks.
>>> _______________________________________________
>>> SNMP4J mailing list
>>>   SNMP4J at agentpp.org
>>>   http://lists.agentpp.org/mailman/listinfo/snmp4j
>> -- 
>> ---
>> AGENT++
>> Maximilian-Kolbe-Str. 10
>> 73257 Koengen, Germany
>> https://agentpp.com
>> Phone: +49 7024 8688230
>> Fax:   +49 7024 8688231
>>
>> _______________________________________________
>> SNMP4J mailing list
>> SNMP4J at agentpp.org
>> http://lists.agentpp.org/mailman/listinfo/snmp4j
> _______________________________________________
> SNMP4J mailing list
> SNMP4J at agentpp.org
> http://lists.agentpp.org/mailman/listinfo/snmp4j

-- 
---
AGENT++
Maximilian-Kolbe-Str. 10
73257 Koengen, Germany
https://agentpp.com
Phone: +49 7024 8688230
Fax:   +49 7024 8688231




More information about the SNMP4J mailing list