You are not logged in.
I am having a problem with the ufw firewall. When I enable it, as the root user:
ufw enable
Firewall is active and enabled at system startup
So far, so good. At this point the contents of /etc/ufw/ufw.conf are:
# /etc/ufw/ufw.conf
#
# Set to yes to start on boot. If setting this remotely, be sure to add a rule
# to allow your remote connection before starting ufw. Eg: 'ufw allow 22/tcp'
ENABLED=yes
# Please use the 'ufw' command to set the loglevel. Eg: 'ufw logging medium'.
# See 'man ufw' for details.
LOGLEVEL=low
No obvious problem there.
However, after a reboot, or a cold start:
ufw status
Status: inactive
This was not expected. On any other distro I have used, the firewall remained active after a reboot.
Is there anything else I need to add to ufw.conf? Or anything else to configure to make the firewall start automatically on system startup?
Last edited by alpage2 (2022-06-21 07:21:12)
Offline
The archwiki has a fairly comprehensive page on ufw.
It says for example that you need to systemctl start ufw.service to expect it to be started by systemd at boot.
Architecture: pentium4, Testing repos: Yes, Hardware: EeePC 901+2GB RAM+OS half on the SD card.
Offline
levi - many thanks for that - it got me there.
systemctl start ufw.service
started the firewall, but after a reboot, it was again inactive.
I then gave it:
systemctl enable ufw
to enable it at boot time, and now it starts at boot time, as intended.
Offline
Sorry, yes, my typo. systemctl enable is what you want for anything starting at boot. Luckily the wiki page is already correct.
Architecture: pentium4, Testing repos: Yes, Hardware: EeePC 901+2GB RAM+OS half on the SD card.
Offline