ipt-netflow icon indicating copy to clipboard operation
ipt-netflow copied to clipboard

Couldn't load target `NETFLOW' debian 11.7 kernel 5.10.0-22

Open avelok opened this issue 2 years ago • 2 comments

Hi can't run ipt_netflow 2.6-17 in iptables v1.8.7 in debian 11.7 kernel Linux testnat 5.10.0-22 Linux testnat 5.10.0-22-amd64 #1 SMP Debian 5.10.178-3 (2023-04-22) x86_64 GNU/Linux

When installing ipt_netflow specified options ./configure --enable-natevents

cat /proc/net/stat/ipt_netflow ipt_NETFLOW 2.6-17-g0eb2092, srcversion 9D57791DE7AEF9589512DAB; llist nel

loading ipt_netflow via modprobe lsmod | grep ipt_NETFLOW ipt_NETFLOW 77824 0 nf_conntrack 176128 4 nf_nat,ipt_NETFLOW,xt_nat,nf_conntrack_netlink x_tables 53248 7 iptable_filter,nft_compat,xt_NAT,ipt_NETFLOW,xt_nat,ip_tables,iptable_mangle

When trying to write a rule in iptables iptables -I FORWARD -j NETFLOW iptables -I INPUT -j NETFLOW iptables -I OUTPUT -j NETFLOW

I get an error iptables v1.8.7 (legacy): Couldn't load target `NETFLOW':No such file or directory

Try `iptables -h' or 'iptables --help' for more information.

tried to reinstall ipt_netflow , specified --ipt-lib in options but didn't help

via strace show me

strace iptables -A INPUT -j NETFLOW 2>&1 | grep NETFLOW execve("/usr/sbin/iptables", ["iptables", "-A", "INPUT", "-j", "NETFLOW"], 0x7ffc04429a40 /* 18 vars */) = 0 stat("/usr/lib/x86_64-linux-gnu/xtables/libipt_NETFLOW.so", 0x7fff7e60ccb0) = -1 ENOENT (No such file or directory) stat("/usr/lib/x86_64-linux-gnu/xtables/libxt_NETFLOW.so", 0x7fff7e60ccb0) = -1 ENOENT (No such file or directory) stat("/usr/lib/x86_64-linux-gnu/xtables/libipt_NETFLOW.so", 0x7fff7e60cce0) = -1 ENOENT (No such file or directory) stat("/usr/lib/x86_64-linux-gnu/xtables/libxt_NETFLOW.so", 0x7fff7e60cce0) = -1 ENOENT (No such file or directory) write(2, "Couldn't load target NETFLOW':N"..., 57Couldn't load target NETFLOW':No such file or directory

Help how to solve this problem. Thanks.

avelok avatar Aug 15 '23 06:08 avelok

Hi,

libipt_NETFLOW.so/libip6t_NETFLOW.so you have in wrong place after install they should be in /lib/x86_64-linux-gnu/xtables.

You can findtheir current location by this command:

find /lib -iname "*NETFLOW.so"

and copy these 2 files into the location which I mentioned above

Best, Łukasz Kalamłacki

kalamlacki avatar Aug 15 '23 15:08 kalamlacki

close, helped

avelok avatar May 30 '24 09:05 avelok