Debian开启SSH开机自启实现方法,debian开启ssh


Debian从8.0开始,默认关闭了SSH。打开的方式如下:

1、修改sshd_config文件,命令为:nano /etc/ssh/sshd_config?

2、将#PasswordAuthentication no的注释去掉,并且将NO修改为YES ?//我的kali中默认是yes,密码验证

3、将#PermitRootLogin yes的注释去掉 //我的kali中默认去掉了注释,允许root登陆

4、启动SSH服务,命令为:/etc/init.d/ssh?start // 或者service ssh start

5、验证SSH服务状态,命令为:/etc/init.d/ssh status

6. 添加开机自启动?? update-rc.d ssh enable
 

关闭则为:

update-rc.d ssh disabled

自启动需要重启生效

相关内容