Ubuntu允许root用户登录
Ubuntu允许root用户登录
由于ubuntu默认不允许root用户远程登录,则需要以下设置:
-
以普通用户登录到目标服务器
ssh <User Name>@<IP Address> -
切换到root用户并设置密码
sudo -i passwd -
编辑配置文件
/etc/ssh/sshd_confg允许root用户远程登录vim /etc/ssh/sshd_config ... PermitRootLogin yes ... -
重启
sshd服务systemctl status sshd.service systemctl restart sshd.service systemctl status sshd.service
浙公网安备 33010602011771号