gentoo iptables rules survive reboot

From thelinuxwiki
Jump to: navigation, search

gentoo will automatically load rules from when starting iptables...

/var/lib/iptables/rules-save

the file above is saved by running...

/etc/init.d/iptables save

So, as long as iptables is in your default run level for automatic startup, and you rules are saved, they will survive a reboot. Don't forget about ipforwarding too.


fwbuilder

When using fwbuilder to install rules to gentoo, the easiest way for the rules to survive reboot is to...

Firewall object -> Firewall Settings... -> Prolog/Epilog ->

add "/etc/init.d/iptabels save" to Epilog (bottom) window under the header "The following commands will be added veratim after generated configuration"