nth module not available on minimal ISO

Issues related to configuring your network
Post Reply
rogier
Posts: 1
Joined: 2015/04/30 18:52:48

nth module not available on minimal ISO

Post by rogier » 2015/04/30 19:00:02

When I try to set up a load balancing rule on my minimal ISO installation of CentSO 7 x64, I get an error:

Code: Select all

[root@milos ~]# iptables -A PREROUTING -i ens160:0 -p tcp --dport 80 -m state --state NEW -m nth --counter 0 --every 2 --packet 0 -j DNAT --to-destination 172.17.98.16:80
iptables v1.4.21: Couldn't load match `nth':No such file or directory
I've seen other posts on related issues but the error message is somewhat different. It looks like I'm missing a module. conntrack is installed:

Code: Select all

[root@milos ~]# rpm -qa|grep conn
libnetfilter_conntrack-1.0.4-2.el7.x86_64
What package do I need to install to get it working?

rgrds rgr

giulix63
Posts: 1305
Joined: 2014/05/14 10:06:37
Location: UK

Re: nth module not available on minimal ISO

Post by giulix63 » 2015/05/04 17:32:04

None. The match extension you're looking for is named "statistic" and is available in the standard iptables distribution (/usr/lib64/xtables/libxt_statistic.so). Try:

Code: Select all

... -m statistic --mode nth --every 2 --packet 0 ...
See iptables extensions (search for statistic)
Root is evil: Do not use root (sudo) to run any of the commands specified in my posts unless explicitly indicated. Please, provide the necessary amount of context to understand your problem/question.

Post Reply