1、Debian开启ssh服务
sudo apt update -y
sudo apt install ssh
2、编辑配置文件
sudo apt install vim
vim /etc/ssh/sshd_config
3、将#PermitRootLogin prohibit-password的注释去掉,设置为yes
4、将#PasswordAuthentication no的注释去掉,并且设置为yes
5、保存退出
:wq
6、重启 SSH 服务
sudo systemctl restart sshd
结束!