DNAT Internet gate problem on centos

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



Hello Guys,

I got trouble to get vserver work as gate:

GATE=XX.XX.XX.XX

YY_PORT=YY

echo "1" > /proc/sys/net/ipv4/ip_forward

iptables -F -t nat

iptables -t nat -A PREROUTING -p tcp -i venet0:0 --dport $YY_PORT \
       -j DNAT --to-destination $GATE:$YY_PORT

iptables -t nat -A POSTROUTING -p tcp --dport $YY_PORT \
       -j MASQUERADE


iptables -L -t nat


Any suggestion? I got it in the past, but now I'm completely confused.

Thanks for help.

Sincerely

Andy


_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
https://lists.centos.org/mailman/listinfo/centos



[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux