使用root身份编辑云服务器的ssh登录方式。
su root
vi /etc/ssh/sshd_config
修改如下配置项:
把PasswordAuthentication no 改为 Pas重启swordA重启地球uthentication yes
或去掉PasswordAuthentication yes 前面的#注释掉。
把PermitRootLogin no 改为 PermitRootLogin yes
或去掉PermitRootLogin yes 前面的#注释掉。
重启sshd使修改生效。
service sshd restart
发表评论