l/etc/ssh/sshd_config
增加允许的IP访问
allowusers XXX@ip
xxx:登录用户
ip:允许访问的IP
保存,重启
我的是centos7,所以是:
/bin/systemctl restart sshd.service
本文介绍如何在CentOS 7中配置SSH服务,通过编辑sshd_config文件,添加allowusers行来指定允许访问的用户及其IP地址,完成设置后需重启sshd服务。
l/etc/ssh/sshd_config
增加允许的IP访问
allowusers XXX@ip
xxx:登录用户
ip:允许访问的IP
保存,重启
我的是centos7,所以是:
/bin/systemctl restart sshd.service

被折叠的 条评论
为什么被折叠?