firewalld for Red Hat systems
So far, we've looked at iptables, a generic firewall management system that's available on all Linux distros, and ufw, which is only available for Ubuntu. For our next act, we turn our attention to firewalld, which is specific to Red Hat Enterprise Linux 7 and all of its offspring.
Unlike ufw for Ubuntu, firewalld isn't just an easy-to-use frontend for iptables. Rather, it's an entirely new way of doing your firewall business, and it isn't compatible with iptables. Understand, though, that iptables still comes installed on the Red Hat 7 family, but it isn't enabled, because you can't have iptables and firewalld enabled at the same time. If you have to use older shell scripts that leverage iptables, you can disable firewalld and enable iptables.
Note
The reason that iptables and firewalld are incompatible is that iptables stores its rules in plain text files in the /etc/sysconfig
directory, and firewalld stores its rules files in .xml
format files in the /etc/firewalld...