Skip to contentSkip to conversation

How many rules were supported iptables?

DISCUSSION 이근수 2 participants 2 messages Oct 20, 2006 netfilter

lore
Share & tools
lore

이근수

author
#0 lore raw

Hi All.
I have a problem that is how many rules were supported iptables.
The program which I maintain and repair generated iptables rules automatically.
Now, I encounter this problem.
Source and destination IP address is written range by user.( ex, 1.1.1.1~1.1.1.10 ) then our program generated 10 IP address(1.1.1.1, 1.1.1.2, 1.1.1.3, … , 1.1.1.10) and make 10 iptables rules. Unfortunately, user wrote iptables rules like this, 10,000 rules is generated.
 “ iptalbes –A FORWARD –p tcp –s 1.1.1.1~1.1.1.100 –d 2.2.2.1~2.2.2.100 –j QUEUE”.
Do 10,000 rules operate safely?? Or Some rules don’t operate normally??
If some rules don’t operate normally, how many rules iptables does support??

#1 lore raw

Zitat von ì�´ê·¼ìˆ˜ <[email protected]>:

Quoted 2 lines

If some rules don't operate normally, how many rules iptables does support??

According to my own tests on a dual Opteron 2,4 GHz-System with 2 GB RAM, more than 5000 rules decreased the throughput dramatically to abround 4 MBit/s an a 100MBit interface, even through, these were empty rules with no -j target. Having such a target will surely decrease the throughput even more. Thus is discourage you from using so many rules.

so long
Maik