CentOS7 默认使用的是firewall作为防火墙
1.查看防火墙状态
firewall-cmd --state
systemctl status firewalld
service firewalld status
2.停止firewall
systemctl stop firewalld.service
systemctl stop firewalld
service firewalld stop
3.开启firewall
firewall-cmd --state
systemctl start firewalld
service firewalld start
4.禁止firewall 开机启动
systemctl disable firewalld.service