为什么Linux服务器意外地closures了SSH客户端并杀死了我所启动的所有进程?

我正在使用CentOS( CentOS release 6.4 (Final) )将数据上传到群集,带宽达到约100MByte / s(净使用率已满)。 另外,运行一个redis(v = 3.2.1)服务器(0.0.0.0:6379)以保持上传状态。 我在后端运行redis-server(SSH退出后不退出):

 $ (redis-server redis.conf &) 

通过从另一个Linux(名称跳转服务器)loginCentOS,CentOS有时(并不总是会发生,但经常)会closuresSSH客户端:

 Connection to <CentOS-ip> closed by remote host. 

-vvv选项添加为ssh -vvv root@centos-ip ,当服务器closures连接时,我得到更多的消息:

 $ debug3: Wrote 64 bytes for a total of 11549 debug1: channel 0: free: client-session, nchannels 1 debug3: channel 0: status: The following connections are open: #0 client-session (t4 r0 i0/0 o0/0 fd 4/5 cc -1) debug3: channel 0: close_fds r 4 w 5 e 6 Connection to <CentOS-ip> closed by remote host. Connection to <CentOS-ip> closed. Transferred: sent 8520, received 82248 bytes, in 474.0 seconds Bytes per second: sent 18.0, received 173.5 debug1: Exit status -1 

和redis服务器也走了! 我grep ed redis.log(DBEUG级别),没有错误或崩溃提示。 我在服务器上开始了一个困倦的过程:

 # sleep.py import time while 1: time.sleep(1) # run as (python sleep.py &) 

SSHclosures后,过程也一样了!

为什么会发生? 凌乱的事实是, 所有的过程我开始走了! 为什么?

可能有很多原因导致这个问题,请给我一些提示,我可以提供其他信息来debugging问题,如果需要的话。 非常感谢。

路由中间的某些TCP / IP堆栈,如服务器和端点客户端之间的中间跳,实际上会导致连接closures,如果不使用keepalive并且保持KeepAlive数据包不发送连接::: :: Try :::

 ssh -o TCPKeepAlive=yes -o ServerAliveInterval=15 -i ~/MYDIR/id_rsa ec2-user(or--root)@myserver.com 

这是否帮助你保持联系?