互联网服务Linux ssh

SSH 连接 linux session经常被服务端关闭

远程连接一台linux机器,centos 5.6. 刚登录session就飞了,有的时候就不飞,具体报错如下,求大侠帮忙看看。我尝试过的方法:1. 不是ssh idle session问题,应为是session刚登录就飞了。2. 也设置过ClientAliveInterval的参数,重启SSH都问题依旧。# grep -i client /etc/ssh/sshd_co...显示全部
远程连接一台linux机器,centos 5.6. 刚登录session就飞了,有的时候就不飞,具体报错如下,求大侠帮忙看看。

我尝试过的方法:
1. 不是ssh idle session问题,应为是session刚登录就飞了。
2. 也设置过ClientAliveInterval的参数,重启SSH都问题依旧。
# grep -i client /etc/ssh/sshd_config
#ClientAliveInterval 0
#ClientAliveCountMax 3
ClientAliveInterval 300
ClientAliveCountMax 20
3. 不是防火墙问题,局域网连接也有一样的报错。
4. 局域网IP没有冲突。

报错信息:
[root@host1 ~]# Read from remote host 10.2.135.5: Connection reset by peer
Connection to 10.2.135.5 closed.


Debug log:
Jun  9 19:16:07 host1 sshd[14856]: debug1: PAM: reinitializing credentials
Jun  9 19:16:07 host1 sshd[14856]: debug1: permanently_set_uid: 0/0
Jun  9 19:16:11 host1 sshd[14852]: Read error from remote host 10.2.73.101: Connection reset by peer
Jun  9 19:16:11 host1 sshd[14852]: debug1: do_cleanup
Jun  9 19:16:11 host1 sshd[14852]: debug1: PAM: cleanup
Jun  9 19:16:11 host1 sshd[14852]: debug1: PAM: closing session
Jun  9 19:16:11 host1 sshd[14852]: pam_unix(sshd:session): session closed for user root
Jun  9 19:16:11 host1 sshd[14852]: debug1: PAM: deleting credentials
Jun  9 19:16:11 host1 sshd[14852]: debug1: session_pty_cleanup: session 0 release /dev/pts/0收起
参与5

查看其它 3 个回答daigw的回答

daigwdaigw系统工程师深圳融博
会不会是linux上的路由配置问题
软件开发 · 2014-06-20
浏览8682

回答者

daigw
系统工程师深圳融博
擅长领域: 虚拟化云计算PowerVM

daigw 最近回答过的问题

回答状态

  • 发布时间:2014-06-20
  • 关注会员:1 人
  • 回答浏览:8682
  • X社区推广