UFW Status Inactive Ubuntu 22.04

UFW Status Inactive Ubuntu 22.04

If you are working in Apache 2 Ubuntu system and if you run ufw status command on terminal then you see “ufw status inactive”. And then if you want to enable or activate UFW firewall in your Ubuntu apache 2 system then you can run sudo ufw Enable for that.

In this tutorial, you will learn how to check ufw firewall status and activate/enable ufw firewall in ubuntu apache 2 system.

How to Activate/Enable ufw Firewall in Ubuntu 22.04

Steps to check ufw status and enable/active ufw firewall in ubuntu 22.04 apache 2:

  • Step 1: Open a Terminal
  • Step 2: Check UFW Status
  • Step 3: Active/Enable UFW
  • Step 4: Reload UFW

Step 1: Open a Terminal

To check the status of UFW on your Ubuntu system, you’ll need to use the Terminal. You can open the Terminal by pressing Ctrl + Alt + T or by searching for “Terminal” in the applications menu.

Step 2: Check UFW Status

Next, execute the sudo ufw status command on terminal to check the status of UFW:

sudo ufw status

If UFW is active, you’ll see output similar to:

Status: active

To                         Action      From
--                         ------      ----
OpenSSH                    ALLOW       Anywhere

If UFW is inactive, you’ll see output similar to:

Status: inactive

If UFW is active, the output will display a list of rules and their corresponding actions (ALLOW or DENY). These rules define how traffic is allowed or denied on different ports.

If UFW is inactive, the output will simply state “Status: inactive,” which means UFW is not currently enforcing any firewall rules.

Step 3: Active/Enable UFW

If UFW is inactive and you’d like to activate or enable it, you can use the following command:

sudo ufw enable

After enabling UFW, you can check its status again using the sudo ufw status command. You can then configure your firewall rules according to your requirements.

Step 4: Reload UFW

If you modify the rules, you need to reload UFW for the changes to take effect:

sudo ufw reload

Conclusion

That’s it; you have successfully learned how to check ufw status and activate/enable ufw firewall in ubuntu apache 2 system.

Recommended Tutorials

AuthorAdmin

My name is Devendra Dode. I am a full-stack developer, entrepreneur, and owner of Tutsmake.com. I like writing tutorials and tips that can help other developers. I share tutorials of PHP, Python, Javascript, JQuery, Laravel, Livewire, Codeigniter, Node JS, Express JS, Vue JS, Angular JS, React Js, MySQL, MongoDB, REST APIs, Windows, Xampp, Linux, Ubuntu, Amazon AWS, Composer, SEO, WordPress, SSL and Bootstrap from a starting stage. As well as demo example.

Leave a Reply

Your email address will not be published. Required fields are marked *