Ubuntu开启SSH服务并配置root登录

314 字  |  2 分钟

系统:Ubuntu18.04+;Debian;Manjaro;OpenWRT;FreeBSD

安装sshd服务

apt install openssh-server

查看ssh服务状态

/etc/init.d/ssh status

修改sshd配置文件

vim /etc/ssh/sshd_config

修改如下信息

#PermitRootLogin prohibit-password

改为

PermitRootLogin yes

#PasswordAuthentication yes

去掉前面#注释

PasswordAuthentication yes

重启sshd服务

/etc/init.d/ssh restart

设置开机启动

update-rc.d ssh enable

评论(没有评论)

谢谢你请我喝咖啡~

扫码打赏,支持一下