Ubuntu 服务器配置远程登录
1.使用命令安装启用 SSH
1 | |
这里需要输入一下 y ,表示确定
检查 ssh 服务是否启动成功
1 | |
如果有 sshd 则说明 ssh 服务已启动,如果没有启动,输入下边命令启动 ssh 服务
1 | |
开启 root 用户远程登录
如果是 root 用户登录,则会提示失败的情况
1 | |
找到 PermitRootLogin 去掉前边的 # ,后边修改为 yes
允许ssh密码登录权限
修改PasswordAuthentication no为:PasswordAuthentication yes。
保存后重启 ssh 服务
1 | |
Ubuntu 服务器配置远程登录
https://cuifuan.github.io/2023/03/01/linux/ubuntu-remote-login/