擅长:python、mysql、java
<p>我肯定会在这两台机器上安装Wireshark,并比较所有场景。在</p>
<p>具体来说:</p>
<blockquote>
<p><a href="https://superuser.com/questions/720851/connection-refused-vs-no-route-to-host">https://superuser.com/questions/720851/connection-refused-vs-no-route-to-host</a></p>
<p>"Connection refused" means that the target machine actively rejected the connection... one of the following things is likely the reason:</p>
<ul>
<li>Nothing is listening on the port</li>
<li>The firewall is blocking the connection with REJECT</li>
</ul>
<p>The ICMP message, "no route to host," means that ARP cannot find the
layer-2 address for the destination host. Usually, this means that
that the host with that IP address is not online or responding.</p>
</blockquote>
<p>当然,这回避了一个问题,为什么Python的行为方式是一种,而Java的行为方式却不同。。。在同一台机器上。在</p>
<p>再次-我鼓励你看看Wireshark。特别是,看看1)三路TCP握手,2)它前面的ARP调用。在</p>
<hr/>
<p>注:正如马尔特上面所说:</p>
<blockquote>
<p>0.0.0.0 ... the address is simply not routable. </p>
</blockquote>
<p>{a1}你可以上窗户了</p>
<p>这就引出了一个问题,为什么你会被“拒绝连接”。在</p>
<p>再说一遍-我很好奇Wireshark给你看了什么。在</p>