设置方式
终端执行命令行
sudo vi /etc/ssh/sshd_config
然后按 Insert 进如编辑模式,方向键上下左右找到 PermitRootLogin 和 PasswordAuthentication 进行修改
PermitRootLogin yes
PasswordAuthentication yes
然后执行
sudo service sshd reload
更改密码
sudo passwd root

设置方式
终端执行命令行
sudo vi /etc/ssh/sshd_config
然后按 Insert 进如编辑模式,方向键上下左右找到 PermitRootLogin 和 PasswordAuthentication 进行修改
PermitRootLogin yes
PasswordAuthentication yes
然后执行
sudo service sshd reload
更改密码
sudo passwd root