Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top
[root@router ~]# iptables -A INPUT -j ACCEPT
iptables: No chain/target/match by that name.

How is that possible? I recompiled the kernel (3.11.8) and updated iptables to 1.4.16. The strage thing is that if I manually put the above rule in /etc/sysconfig/iptables and I issue the command /etc/init.d/iptables restart (I'm on CentOS 6.4) it works! It inserts the rule.

My lsmod | grep ipt:

iptable_mangle         12695  1 
ipt_MASQUERADE         12759  3 
iptable_nat            12810  1 
nf_nat_ipv4            13263  1 iptable_nat
nf_nat                 25997  3 ipt_MASQUERADE,iptable_nat,nf_nat_ipv4
nf_conntrack           95633  7 xt_state,ipt_MASQUERADE,iptable_nat,nf_nat_ipv4,nf_nat,nf_conntrack_ipv4,xt_conntrack
iptable_filter         12810  1 
ip_tables              27213  3 iptable_mangle,iptable_nat,iptable_filter

iptables -L output:

Chain INPUT (policy ACCEPT)
target     prot opt source               destination         

Chain FORWARD (policy ACCEPT)
target     prot opt source               destination         

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination  
share|improve this question
    
What's the output of iptables -L ? – Lawrence Nov 21 '13 at 1:07
    
Added to the question. – Francesco Zanini Nov 21 '13 at 16:57
up vote 0 down vote accepted

Found the problem. Basically I did a make uninstall of the iptables 1.4.16 version and compiled from source the 1.4.20 version (latest available now). Now it works perfectly.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .