No supported authentication methods available (server sent: publickey)错误解决

发布时间 2023-10-26 20:40:13作者: CrossPython

No supported authentication methods available (server sent: publickey)错误解决
Putty, WinScp或者Filezilla在远程登录的时候出现No supported authentication methods available (server sent: publickey)的错误的解决方法。

centos 7和Ubuntu系统来说解决方式应该大同小异。首先通过ssh登录到工作站或者服务器,cd到/etc/ssh目录下,然后打开sshd_config文件,本人使用vi编辑器,Ubuntu如下:

sudo vi sshd_config

 

s保存

修改完毕后保存退出。
最后Centos使用systemctl restart sshd命令重启sshd。

Ubuntu使用sudo service ssh stop先停止服务,在使用sudo service ssh start开启服务

通过sudo ps -e |grep ssh可以查看服务运行情况

然后,再次登录Filezilla或者WinScp就应该没有问题了