CentOS7 关闭防火墙
- CentOS6 关闭防火墙使用以下命令
//临时关闭 service iptables stop //禁止开机启动 chkconfig iptables off
- CentOS7 版本后防火墙默认使用firewalld
- 查询防火墙 - systemctl status firewalld.service
//临时关闭 systemctl stop firewalld //禁止开机启动 systemctl disable firewalld
- 选择安装iptables-service
yum install -y iptables-services //关闭防火墙 service iptables stop Redirecting to /bin/systemctl stop iptables.service //检查防火墙状态 service iptables status Redirecting to /bin/systemctl status iptables.service ● iptables.service - IPv4 firewall with iptables Loaded: loaded (/usr/lib/systemd/system/iptables.service; disabled; vendor preset: disabled) Active: active (exited) since Sun 2018-07-29 08:51:51 EDT; 22min ago Process: 1637 ExecStart=/usr/libexec/iptables/iptables.init start (code=exited, status=0/SUCCESS) Main PID: 1637 (code=exited, status=0/SUCCESS)
link https://jingyan.baidu.com/article/ff42efa9fd8c1cc19e2202bb.html
