Linux CentOS7 turn off the firewall CentOS6 close open close open CentOS firewall firewall

    Linux CentOS7 turn off the firewall CentOS6 close open close open CentOS firewall firewall

 

A, CentOS 7 to close the open firewall

1, start the firewall: systemctl Start firewalld

2, disable the firewall: systemctl STOP firewalld

3, set the boot: systemctl enable firewalld

4, stop and disable the boot: sytemctl disable firewalld

5, restart the firewall: Firewall-cmd --reload

6, view the status: systemctl Status firewalld 

 

Two, CentOS 6 is closed to open the firewall

1, open the firewall (after the restart permanent): chkconfig iptables ON

2, turn off the firewall (after the restart permanent): chkconfig iptables OFF

3, open the firewall (with immediate effect, after the restart failure): Service iptables Start

4, turn off the firewall (with immediate effect, after the restart failure): Service iptables STOP

5, restart the firewall: Service iptables restartd

 

发布了156 篇原创文章 · 获赞 159 · 访问量 49万+

Guess you like

Origin blog.csdn.net/HaHa_Sir/article/details/102732145