肿瘤康复网,内容丰富有趣,生活中的好帮手!
肿瘤康复网 > Linux防火墙的开启 关闭 重启 查看永久处理防火墙(需重启系统后才能生效)

Linux防火墙的开启 关闭 重启 查看永久处理防火墙(需重启系统后才能生效)

时间:2021-08-24 06:16:53

相关推荐

1、概念:

防火墙它具备一定的防护功能,比如说端口的开放和禁止,也可做数据的转发(类似路由功能),策略及其他功能。

临时处理防火墙:如果系统重启,那么防火墙将恢复到之前的状态。此时就需要永久处理防火墙的命令。

2、Linux防火墙开启、关闭、重启、查看相关命令:

开启 命令1:service iptables start

命令2:/etc/init.d/iptables start

关闭 命令1:service iptables stop

命令2:/etc/init.d/iptables stop

重启 命令1:service iptables restart

命令2:/etc/init.d/iptables restart

查看 命令1:service iptables status

命令2:/etc/init.d/iptables status

3、永久处理防火墙命令:

开启:chkconfig iptables on

查看状态:chkconfig iptables --list

关闭:chkconfig iptables off

4、解释说明:

上文中2中的service指在服务层直接运行操作命令,/etc/init.d/iptables指进入linux系统的防火墙存储文件目录进行操作。

上文中3永久处理防火墙之后需要重启linux系统才能生效,直接关闭linux系统然后打开就行。

总结不易,期待您的关注,我们一起进步,冲冲冲!!!

如果觉得《Linux防火墙的开启 关闭 重启 查看永久处理防火墙(需重启系统后才能生效)》对你有帮助,请点赞、收藏,并留下你的观点哦!

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。