SSH登陆SMB服务器时出现提示 “ssh_exchange_identification -: Connection closed by remote host”,不过本地可以登陆到其他主机。努力了一会,没有成功, 于是GOOGLE,几乎没有发现什么有价值的东西!
不过下面这信件,瞒有意思的
————————–
ssh_exchange_identification: Connection closed by remote host
But this is not a good resolvent for me ! T_T
ssh_exchange_identification: Connection closed by remote host (solved)
January 07, 2005
Kept getting this error message when trying to connect to my server. As usually when you google you find all kinds of pundits giving stupid answers in many a mailing list.
In this case all the answers said it’s a problem with the hosts.allow file or libwrap. libwrap my foot. It’s just a matter of connections not being closed properly and the number of allowed connections being used up.
The server in question, the one that refused to let me in, is a server that I login to on an almost daily basis. On a previous occaision I had the exact same message when I had too many upload and downloads threads running with our sftp client, so I knew straight away what the problem was.
So what’s the solution: sleep on it! I am serious, by the time you call your hosting companies customer support and they get around to restarting your server (which for a company like aitcom can be measured in days) the problem would have solved itself when the connections timed out.
If you keep attempting to reconnect this will not happen. So close all your ssh and sftp clients and go for a walk when you come back you will find that you can login again.
—————————-
大致就是说,很多人遇到这样的问题就去找身份验证的问题,找./ssh/known_hosts 这样的文件的问题,其实不是这么回事,可能更多的情况是因为连接的线程太多,导致拒绝服务。所以别瞎操心了,把服务器重新启动一下吧,然后睡一觉,就好了,呵呵。
重新启动了一下服务器,不出现这个提示了,不过还是连接不上,但觉得离搞定不远了,ssh connection refused,登陆webmin,再修改了一下配置,然后按启动提示的错误信息修改。再次启动,提示/var/empty/ssh 权限设置错误,于是修改权限为700, #service ssh restart . ok !
问题解决。
一个小小的问题从今天凌晨折腾到下午