RHEL 7 Fedora – How to Enable iptables Instead of firewalld Services

fedorafirewalldiptablesrhel7

The newest fedora has firewalld as new firewall aplication. I liked old iptables services. I want them back but have no idea how to do that. I have tried :

systemctl disable firewalld.service
systemctl stop firewalld.service
systemctl enable iptables.service
systemctl enable ip6tables.service
systemctl start iptables.service
systemctl start ip6tables.service

But it does not work! Didn't find any help on wiki or google.

Disabling firewalld work ok, but when I'm trying to enable iptables.service I get:

systemctl enable iptables.service
Failed to issue method call: No such file or directory

Best Answer

Make sure you have the iptables-services package installed. This legacy package provides the systemd scripts for the previous iptables invocation. This package is not always installed, depending on your installation choices when you installed (or upgraded).

yum install iptables-services

And of course, if possible, you should use the new firewalld system. It should only be necessary to revert to the old system if firewalld fails to provide a feature you need.