[SOLVED] Does Anyone Know Why My UFW Keeps Turning Itself Off?

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read how to get help
Gamemasta114
Level 1
Level 1
Posts: 35
Joined: Wed Jun 05, 2019 8:58 pm

Re: Does Anyone Know Why My UFW Keeps Turning Itself Off?

Post by Gamemasta114 » Fri Aug 23, 2019 10:24 pm

LuvNix wrote:
Fri Aug 23, 2019 10:19 pm
^Yep reboots, android autocorrect. OP then don't know what else to suggest. Just installed it/ufw went through similar and it's working fine now and was same situation 8/9yrs ago when dorking with ufw. Good luck though.

Plus there are other gnu/nix firewalls. If ufw keeps being a pain
Do you have any recommendations? If this is a lost cause then I'm not necessarily opposed to switching to something else. Just so long as it's not the firewall equivalent of Gentoo (complicated) lol.

all41
Level 15
Level 15
Posts: 5587
Joined: Tue Dec 31, 2013 9:12 am
Location: Computer, Car, Cage

Re: Does Anyone Know Why My UFW Keeps Turning Itself Off?

Post by all41 » Fri Aug 23, 2019 10:31 pm

@Gamemasta114
Just a very isolated issue.
Hang around here for a solution--it may come from the opposite side of the globe.

Gamemasta114
Level 1
Level 1
Posts: 35
Joined: Wed Jun 05, 2019 8:58 pm

Re: Does Anyone Know Why My UFW Keeps Turning Itself Off?

Post by Gamemasta114 » Fri Aug 23, 2019 10:36 pm

all41 wrote:
Fri Aug 23, 2019 10:31 pm
@Gamemasta114
Just a very isolated issue.
Hang around here for a solution--it may come from the opposite side of the globe.
Ok, will do. Thanks for your help.

LuvNix
Level 3
Level 3
Posts: 127
Joined: Wed Jan 02, 2019 4:50 pm

Re: Does Anyone Know Why My UFW Keeps Turning Itself Off?

Post by LuvNix » Fri Aug 23, 2019 10:39 pm

Not really, quit messing with those gooey firewalls a long time ago too. Can't even remember what they're called. Still can't get what's going on with ufw there.

Does your Mint OS have rsyslog installed? Its a recommend of ufw. I don't use Mint but rsyslog is installed on this OS. Just a long shot thought, something else to check.

gm10
Level 18
Level 18
Posts: 8738
Joined: Thu Jun 21, 2018 5:11 pm

Re: Does Anyone Know Why My UFW Keeps Turning Itself Off?

Post by gm10 » Fri Aug 23, 2019 11:02 pm

Gamemasta114 wrote:
Fri Aug 23, 2019 9:53 pm
I ran your command as well as sudo ufw enable again and the problem persists.
Ok, no problem, just had to check. I really don't know what's causing this (you should still check the log files) but we can prevent ufw from getting disabled. Make sure the firewall is enabled, then run this:

Code: Select all

sudo chattr +i /etc/ufw/ufw.conf
This makes that configuration file immutable, i.e. it cannot be changed anymore. Reboot to confirm it works as I expect it will. Bit of a hacky way to go about it but eh, beggars can't be choosers, at least while we don't know the actual cause of the issue. ;)
Tune up your LM 19.x: ppa:gm10/linuxmint-tools

all41
Level 15
Level 15
Posts: 5587
Joined: Tue Dec 31, 2013 9:12 am
Location: Computer, Car, Cage

Re: Does Anyone Know Why My UFW Keeps Turning Itself Off?

Post by all41 » Fri Aug 23, 2019 11:13 pm

gm10 wrote:
Fri Aug 23, 2019 11:02 pm
Gamemasta114 wrote:
Fri Aug 23, 2019 9:53 pm
I ran your command as well as sudo ufw enable again and the problem persists.
Ok, no problem, just had to check. I really don't know what's causing this (you should still check the log files) but we can prevent ufw from getting disabled. Make sure the firewall is enabled, then run this:

Code: Select all

sudo chattr +i /etc/ufw/ufw.conf
This makes that configuration file immutable, i.e. it cannot be changed anymore. Reboot to confirm it works as I expect it will. Bit of a hacky way to go about it but eh, beggars can't be choosers, at least while we don't know the actual cause of the issue. ;)
curious: this file is immutable by default

Gamemasta114
Level 1
Level 1
Posts: 35
Joined: Wed Jun 05, 2019 8:58 pm

Re: Does Anyone Know Why My UFW Keeps Turning Itself Off?

Post by Gamemasta114 » Fri Aug 23, 2019 11:17 pm

gm10 wrote:
Fri Aug 23, 2019 11:02 pm
Gamemasta114 wrote:
Fri Aug 23, 2019 9:53 pm
I ran your command as well as sudo ufw enable again and the problem persists.
Ok, no problem, just had to check. I really don't know what's causing this (you should still check the log files) but we can prevent ufw from getting disabled. Make sure the firewall is enabled, then run this:

Code: Select all

sudo chattr +i /etc/ufw/ufw.conf
This makes that configuration file immutable, i.e. it cannot be changed anymore. Reboot to confirm it works as I expect it will. Bit of a hacky way to go about it but eh, beggars can't be choosers, at least while we don't know the actual cause of the issue. ;)
You're awesome! That worked. Sorry to have taken up so much of your time tonight but I definitely appreciate all the help. I'm completely happy with a hacky fix lol. Although I do want to chase this down a bit more this weekend, especially because I have this same problem on an Ubuntu vanilla install, completely different machine which makes me think it may be something that I've done/installed common to both computers. Anyway, thanks so much again.

gm10
Level 18
Level 18
Posts: 8738
Joined: Thu Jun 21, 2018 5:11 pm

Re: Does Anyone Know Why My UFW Keeps Turning Itself Off?

Post by gm10 » Sat Aug 24, 2019 12:21 am

all41 wrote:
Fri Aug 23, 2019 11:13 pm
curious: this file is immutable by default
Certainly not. Maybe you had to come up with the same "fix" before yourself?
Gamemasta114 wrote:
Fri Aug 23, 2019 11:17 pm
You're awesome! That worked. Sorry to have taken up so much of your time tonight but I definitely appreciate all the help. I'm completely happy with a hacky fix lol. Although I do want to chase this down a bit more this weekend, especially because I have this same problem on an Ubuntu vanilla install, completely different machine which makes me think it may be something that I've done/installed common to both computers. Anyway, thanks so much again.
You're welcome, and no worries, we're all happy to help. Please do let us know should you figure out what causes it on your machines.
Tune up your LM 19.x: ppa:gm10/linuxmint-tools

Post Reply

Return to “Newbie Questions”