Article 6DD2Q iptables v1.8.9 (nf_tables): Need TCP, UDP, SCTP or DCCP with port specification

iptables v1.8.9 (nf_tables): Need TCP, UDP, SCTP or DCCP with port specification

by
Jason.nix
from LinuxQuestions.org on (#6DD2Q)
Hello,
I ran the following iptables rule:
Code:# IF_MAIN=enp0s3:0
# IF_TUNNEL=tun2
# YOUR_OPENVPN_SUBNET=10.10.0.0/16
# iptables -t nat -A POSTROUTING -s $YOUR_OPENVPN_SUBNET -j SNAT --to $IF_MAINI got the following error:
Code:iptables v1.8.9 (nf_tables): Need TCP, UDP, SCTP or DCCP with port specification
Try `iptables -h' or 'iptables --help' for more information.What is the problem?
I changed it as below and problem solved:
Code:# iptables -t nat -A POSTROUTING -s $YOUR_OPENVPN_SUBNET -j SNAT --to 10.0.5.2010.0.5.20 is the IP address of the enp0s3:0 NIC.

Thank you.
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments