The path to iptables is either not set or incorrect for IPTABLES

Post Reply
iserver
Junior Member
Posts: 20
Joined: 17 Sep 2009, 15:59
Location: Acequias (Spain)
Contact:

The path to iptables is either not set or incorrect for IPTABLES

Post by iserver »

Hi.

I've read all post in internet about this. But not work.

After upgrade to Ubuntu 20.04.2 LTS CSF Firewall stop working.

Paths are correct, but still fails.

Code: Select all

 *Error* The path to iptables is either not set or incorrect for IPTABLES [/usr/sbin/ip6tables] in /etc/csf/csf.conf at /usr/local/csf/lib/ConfigServer/URLGet.pm line 26.
Compilation failed in require at /usr/sbin/csf line 21.
BEGIN failed--compilation aborted at /usr/sbin/csf line 21.

Code: Select all

 cat /etc/csf/csf.conf | grep IP6
# This option uses IPTABLES_SAVE, IPTABLES_RESTORE and IP6TABLES_SAVE,
# IP6TABLES_RESTORE in two ways:
IP6TABLES = "/usr/sbin/ip6tables"
IP6TABLES_SAVE = "/usr/sbin/ip6tables-save"
IP6TABLES_RESTORE = "/usr/sbin/ip6tables-restore"
root@dropbox:~# whereis ip6tables
ip6tables: /usr/sbin/ip6tables /usr/share/man/man8/ip6tables.8.gz
root@dropbox:~# whereis ip6tables-save
ip6tables-save: /usr/sbin/ip6tables-save /usr/share/man/man8/ip6tables-save.8.gz
root@dropbox:~# whereis ip6tables-restore
ip6tables-restore: /usr/sbin/ip6tables-restore /usr/share/man/man8/ip6tables-restore.8.gz

My config about IPv6

Code: Select all

 cat /etc/csf/csf.conf | grep IPV6
IPV6 = "0"
IPV6_ICMP_STRICT = "0"
IPV6_SPI = "0"
LF_NETBLOCK_IPV6 = ""
eth0 not IPV6

Code: Select all

2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether 52:54:00:00:a9:77 brd ff:ff:ff:ff:ff:ff
    inet 163.172.231.177/32 brd 163.172.231.177 scope global eth0
       valid_lft forever preferred_lft forever
Testing

Code: Select all

Testing ip_tables/iptable_filter...open3: exec of /sbin/iptables -I OUTPUT -p tcp --dport 9999 -j ACCEPT failed: No such file or directory at /usr/local/csf/bin/csftest.pl line 144.
ForumAdmin
Moderator
Posts: 1502
Joined: 01 Oct 2008, 09:24

Re: The path to iptables is either not set or incorrect for IPTABLES

Post by ForumAdmin »

The error is incorrect as it is referring to ip6tables instead of iptables, therefore is actually failing on the location or permissions of IPTABLES as defined in /etc/csf/csf.conf
iserver
Junior Member
Posts: 20
Joined: 17 Sep 2009, 15:59
Location: Acequias (Spain)
Contact:

Re: The path to iptables is either not set or incorrect for IPTABLES

Post by iserver »

Erro is error showed by csf.

On the other hand, the completely correct permissions, either for iptables or ip6tables

Double and triple check
iserver
Junior Member
Posts: 20
Joined: 17 Sep 2009, 15:59
Location: Acequias (Spain)
Contact:

Re: The path to iptables is either not set or incorrect for IPTABLES

Post by iserver »

Thanks.

I see the error in other machine with Centos 8.

System is a Centos 8 upgrade from Centos 7 with some problem, such iptables. Is installed but is wrong installation.

After correct issues in upgraded system work fine.

Now I try with Ubunut, but problem is possible de same. Is and ubuntu 20 upgrade from Ubuntu 26
Post Reply