In this tutorial, you will learn how to install ufw gui on Ubuntu 22.04.
The ufw firewall is preinstalled in Ubuntu 22.04, which means you don't need to install ufw firewall manually to use it in Ubuntu 22.04. However, ufw doesn't come with a GUI, so you are limited to use it only on the terminal.
So if you wanted let's say to open a port, then the only way would be to do it via the terminal.
If you are not familiar enough with terminal, and want to be able to manage your firewall by using GUI, then you can do so by installing the gui of firewall.
Install gufw on Ubuntu 22.04
In this tutorial, we'll be downloading and installing the
gufw package on Ubuntu 22.04, via apt.
Step 1 - Update the system
Before we begin with this tutorial, ensure that the package database in your system is updated.
The package database contains all the repositories, including the universe repository, which we'll be using to download
gufw the GUI for ufw firewall.
To do so, simply run the command below.
sudo apt update
Step 2 - Install GUFW
The package database should be now refreshed, so you can proceed to install gufw.
gufw can be installed easily via apt in your terminal, as like we said the
gufw package can be downloaded from the default repository of Ubuntu 22.04.
To install gufw, simply run the command below.
sudo apt install gufw -y
Step 3 - Verify gufw installation
The gufw package should be now installed in your system, to verify that gufw is installed correctly in your system, you can use the
apt-cache policy can tell us if
gufw package is installed or not.
apt-cache policy gufw
As you can see, gufw is installed.
Step 4 - Launch gufw
After verifying that gufw package was installed correctly, you should be able to launch and manage your firwall by using GUI.
To launch gufw, you can use the terminal.
You can also launch gufw via the applications menu in your system.
To do so, simply search for "Gufw" in the search box, and click the gufw icon to launch it.
Step 5 - Enable firewall
Once you launch gufw, you will notice that the gufw status is not active, this is because gufw is disabled by default, so in order to use GUI, you need to enable it manually.
To enable gufw simply click the switch button.
Another way of enabling gufw is by using terminal. To enable gufw via the terminal, simply run the command below.
sudo ufw enable
Once you enable the firewall, confirm that it was enabled correctly, by using the
sudo systemctl is-enabled ufw
The output should return "Enabled"
Uninstalling gufw in Ubuntu 22.04
If you no longer need ufw in your system, and want to uninstall it. You can easily do so by using terminal.
sudo apt remove gufw
Next, gufw will be removed from your system.
In this tutorial, you learned how to install the gui for ufw firewall in Ubuntu 22.04.