CentOS 7关闭防火墙

一、防火墙

1、查看防火墙状态

systemctl status firewalld.service

2、关闭防火墙

systemctl stop firewalld.service

3、禁用防火墙

systemctl disable firewalld.service

二、SELinux防火墙

1、查看SELinux防火墙状态

getenforce

2、临时关闭SELinux防火墙

setenforce 0

3、永久关闭SELinux防火墙

vim /etc/sysconfig/selinux

把SELINUX=enforcing改为SELINUX=disabled

三、iptables

1、查看状态

systemctl status iptables.service

2、关闭

systemctl stop iptables.service

3、禁用

systemctl disable iptables.service

你可能感兴趣的:(CentOS,centos,防火墙,selinux,iptables)