sshd服务拒绝的解决办法

Posted on Tue 22 June 2010 in 我用(IT)

连接VPS,错误提示如下: ssh_exchange_identification: Connection closed by remote host

搜了一下,应该是设置了访问限制造成的:需要修改/etc/hosts.allow,加入 sshd: xxx.xxx.xxx.xxxsshd: ALL 改完之后需要重启一下sshd: service sshd restart或/etc/init.d/sshd restart

错误日志,可以看一下/var/log/syslog和/var/log/auth.log

另外还有一种改法:需要查看一下denyhosts是否安装 1) clear out the hosts.deny file 2) restart the denyhosts daemon

参考: http://ubuntuforums.org/showthread.php?t=1011934