May 28, 2017 · FirewallD Firewall-cmd
Basic firewall-cmd commands
Something high up on my most googled list is how to open ports with firewalld. Below you can see how to open a port permanently.
List all open ports:
sudo firewall-cmd --list-all
Open new port permanently:
sudo firewall-cmd --zone=public --permanent --add-port=6789/tcp
Reload firewalld for the change to take effect:
sudo firewall-cmd --reload
To show the actual iptables configuration use this command:
sudo iptables -S