CentOS7查看和关闭防火墙

CentOS 7.0默认使用的是firewall作为防火墙

查看防火墙状态

firewall-cmd --state

显示running,表示防火墙没有关闭

停止firewall

systemctl stop firewalld.service

继续查看防火墙状态,如果显示not runing表示防火墙已经关闭

重新开启防火墙

systemctl start firewalld.service

禁止firewall开机启动

systemctl disable firewalld.service 

猜你喜欢

转载自www.cnblogs.com/guoyansi19900907/p/9016877.html