Linux : How to open a port on RHEL/CentOS 7 firewalld?

By | March 28, 2015

Here is how to open a port and make it permanent with the new firewalld on RedHat/CentOS Linux 7. You can statically edit /etc/firewalld/zones/zone.conf and reload the daemon, but the right way to do is the following.

1. Open the port by specifying the proper zone, port number and protocol. Unless you do not want that rule to survive to a reboot, you have to add the “–permanent” statement :

Example :

2. Then reload the firewall :

Be Sociable, Share!