Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Iptables + forwarding

Status
Not open for further replies.

axman505

Technical User
Jun 20, 2001
489
US
I am trying to forward port 3389 to a local lan address. How do i do this? i can't seem to ge tit right
 
Hi,

You just do a line like this :

/sbin/iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 3389 -j DNAT --to 192.168.1.10

(where eth0 is the incoming interface and 192.168.1.10 is an example of the box to which you are forwarding packets)

Obviously you also need the forwarding turned on in the /proc filesystem in the usual way :

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

Hope this helps



 
i did that, but it doesnt seem to work. Should netstat -at list the port ??? THanks again in advance
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top