当我 ping 我的服务器时,它会响应:
user@localhost:~$ ping my.server
PING my.server (111.111.111.11) 56(84) bytes of data.
64 bytes from my.server (111.111.111.11): icmp_req=1 ttl=42 time=38.4 ms
64 bytes from my.server (111.111.111.11): icmp_req=2 ttl=42 time=50.0 ms
64 bytes from my.server (111.111.111.11): icmp_req=3 ttl=42 time=58.6 ms
^C
--- my.server ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2003ms
rtt min/avg/max/mdev = 38.419/49.037/58.637/8.287 ms
但是当我尝试 ssh 时(我一直在做的事情,并且过去几个小时一直在同一个连接上做),它挂起:
user@localhost:~$ ssh my.server
http://speedtest.net说我的连接下载速度为 1.5 Mbps,上传速度为 0.4 Mbps。
ssh挂起是否有原因?
答案中提供的建议的结果
来自@nsfyn55
user@localhost:~$ telnetmy.server 22
Trying 111.111.111.11...
Connected to my.server
Escape character is '^]'.
SSH-2.0-OpenSSH_4.3
Connection closed by foreign host.
来自@vahid:
user@localhost:~$ nc -v -w 1 111.111.111.111 -z 22
nc: timeout cannot be negative