I'm using Ubuntu 16.04 and until yesterday I used UFW and had only some basic rules. Now I need to have more complex rules and I decided to use iptables (if I understand right, I can't have my firewall rules in file without it).
Now I see an error for netfilter-persistance.service if I run:
sudo systemctl status netfilter-persistent.service
Any idea?
First of all check
for errors. Then have a look at which are rules being loaded by
netfilter-persistent
service. Which are located in/etc/iptables/rules.v4
and/etc/iptables/rules.v6
. The service pretty much just loads firewall rules using:You cat try to debug it line by line (and the same for
rules.v6
). After removing erroneous statement you can restart the service: