iptables: No chain/target/match by that name
Hi all.
When I try to create a rule using the nat table and the PREROUTING chain, always appear a message like this: iptables: No chain/target/match by that name I clean all the iptables rules before implement this rule, so I execute all this iptables commands: pi@raspberrypi:~$ sudo iptables -FI have see many post about this, but most of them ar solved adding the "-t nat" table in the command, or checking the CONNTRACK parameters in the kernel. My CONNTRACK parameters in the active kernel, has these configuration: pi@raspberrypi:~$ cat /boot/config-4.4.0-1-rpi2 | grep CONNTRACKAnd the loaded kernel modules are: pi@raspberrypi:~$ lsmodIf I configure the system, with simple MASQUERADING rules like these: sudo iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADEIt's works perfect. The problem appear when I try to use the PREROUTING chain. If I try to use another PREROUTING sentence like this one, it fails always: pi@raspberrypi:~$ sudo iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 2222 -j DNAT --to-destination 192.168.11.205:22Please any help will be very grateful. Thanks. |
Nobody's helped out yet, so I'll take a lame shot at it. In this 14-year-old example, https://www.netfilter.org/documentat...T-HOWTO-6.html, they change the order of setting the in-interface eth0 when including a destination port. Don't know if that would make a difference, but something to try if you haven't already...
Code:
## Change destination addresses to 5.6.7.8, 5.6.7.9 or 5.6.7.10. Dave |
Please run this commnad:
Code:
iptables-save ~/iptables-rules |
Solved.
Hi all.
Thanks for your help. The problem is solved. Really I don't know how I solve it, but with a reboot of the system, it works without problem. For your info, my iptables-save output is very simple: Code:
pi@raspberrypi:~$ sudo iptables-save Thanks again. |
Great! Glad you solve this problem.
Please edit the subject and add [SOLVED] to it. |
All times are GMT -5. The time now is 02:44 AM. |