关闭防火墙报错

问题:关闭防火墙时报错service iptables status

Redirecting to /bin/systemctl status iptables.service
Unit iptables.service could not be found.

解决方案:

cd /etc/sysconfig

ls -l

没有查看到iptables文件,但存在ip6tables-config和iptables-config,本文中的linux为CentOS 7.6 ,CentOS 7默认没有了iptables文件。

安装iptables-services

启动iptables

查看防火墙状态

猜你喜欢

转载自www.cnblogs.com/chenxi-hxl/p/12361019.html