Oracle Cloud(甲骨文)开启root登录

使用密钥登录系统以后
执行如下命令

sudo -i
复制代码

切换为root用户
接着输入

echo root:19960106ltd|sudo chpasswd root
sudo sed -i 's/^#\?PermitRootLogin.*/PermitRootLogin yes/g' /etc/ssh/sshd_config;
sudo sed -i 's/^#\?PasswordAuthentication.*/PasswordAuthentication yes/g' /etc/ssh/sshd_config;
复制代码

其中19960106ltd为root的密码
重启sshd服务

sudo service sshd restart
复制代码
来发评论吧~
Powered By Valine
v1.4.14