ubuntu18.04开启root登录SSH的方法 |
您所在的位置:网站首页 › linux启用root登录 › ubuntu18.04开启root登录SSH的方法 |
一、用普通账号登录SSH,输入命令切换到临时的root: sudo -i 二、安装SSH apt install openssh-server 三、更改root账户密码 passwd 四、修改ssh配置允许使用root账户SSH登录 1、编辑sshd_config文件 vi /etc/ssh/sshd_config 2、找到以下内容: # Authentication: #LoginGraceTime 2m #PermitRootLogin prohibit-password #StrictModes yes #MaxAuthTries 6 #MaxSessions 10 3、修改为: # Authentication: #LoginGraceTime 2m #PermitRootLogin prohibit-password PermitRootLogin yes StrictModes yes #MaxAuthTries 6 #MaxSessions 10 五、重启ubuntu reboot 六、接下来就可以使用Xshell等工作,以root用户登录ubuntu了。 虚拟机安装相关教程 |
今日新闻 |
推荐新闻 |
CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3 |