1、设置root密码
passwd
2、找到ssh配置信息进行修改
vi /etc/ssh/sshd_config
3、将PasswordAuthentication no 改为 PasswordAuthentication yes
PasswordAuthentication no
PasswordAuthentication yes
4、添加 PermitRootLogin yes ,保存,退出
PermitRootLogin yes
5、重启ssh
service ssh restart