RedHat Enterprise7.1如何关闭防火墙

在RHEL5、6(Redhat Enterprise Linux)的时候,检查防火墙是否开启常用的如下命令:

1.1、永久关闭,重启后生效:

开启:chkconfig iptables on

关闭:chkconfig iptables off

1.2、临时开启,重启后失效:

开启:service iptables start

关闭:service iptables stop


最近使用上了RHEL7的时候,发现原有的命令不支持了,报

Redirecting to /bin/systemctl status iptables.service


需要使用systemctl来进行查看

查看状态systemctl status firewalld

2.1、临时关闭,立即生效:

开启:systemctl start firewalld

关闭:systemctl stop firewalld

临时关闭,即时生效

2.2、永久开启, 重启后生效:

开启:systemctl enable firewalld

关闭:systemctl disable firewalld


PS:

其他常用网络操作命令

service network restart

你可能感兴趣的:(Linux)