Monitor state of UFW firewall

Hello everyone,
not sure if I am in the right place here but I am struggeling with this for a bit:

I want to monitor the state of the UFW on our ubuntu-based firewalls via icinga using nrpe

as far as I see “ufw status” requires root-priviledges.
Is there any other way to determine the state of the firewall without being root or having to fiddle with sudoes files on all of our servers?
We do not have any central configuration management running so this would be quite cumbersome to do

Any help or hints on how to solve this would be greatly appreciated :slight_smile:
Best regards

You might well be better off asking this on an Ubuntu list/forum, or if there
is one, something specific to UFW. Someone here may be able to answer your
question, but I think it’s less likely.

The fact that you want to monitor this with Icinga is not really significant -
the main question is whether you can do it without root priviliege.

Good luck,


Hi, you also can monitor the result of an active Firewall. f.e. what is not working, if the service is not running. Or a logfile entry is created or missing, a process is there or not. a closed port and so on.