The UFW firewall is the default firewall that ships standard with the Ubuntu Linux Distribution. UFW stands for UncomplicatedFirewall.
- To enable the ufw firewall, open a new Terminal window and execute the following command:
sudo ufw enable
- To disable the ufw firewall, open a new Terminal windows and execute the following command:
sudo ufw disable
- To view the status of the ufw execute the below command:
sudo ufw status
sudo iptables -Fwill flush the firewall rules. You won't be able to turn off the firewall as it is built into the kernel.