The firewall of Centos7 is changed to “iptables” and is no longer called “iptables”. The firewall of Centos7 is not called “iptables” anymore. The firewall of Centos7 is changed to “iptables”.
firewall-cmd --zone=public --add-port=80/tcp --permanent
1
Command meaning:
— zone # scope
— add-port=80/ TCP # Add port in format: port/communication protocol
— permanent # is permanent and will fail if restarted without this parameter
Restart firewall:
systemctl stop firewalld.service
systemctl start firewalld.service