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

Re: Kicked me of self! :-/

> So what I need now, is the setup for the IP Tables to  get  the  traffic
> forwarded from eth0/eth1 to the servers in eth2 where I have
> eth0 -> smtp/imap -> <mail.tamay-dogan.net>
>         http      -> <www.tamay-dogan.net>        (VServer)
>         http:9999 -> <www.debian.tamay-dogan.net> (VServer)
> eth2 -> smtp/imap -> <mail.tdwave.net>
>         http      -> <www.tdwave.net>             (VServer)
>         http:9999 -> <www.debian.tamay-dogan.net> (VServer)
>         pgsql     -> <pgsql.private.tamay-dogan.net>

You want to have a look at the DNAT section in the iptables manual.

And to get you up to speed,

	iptables -t nat -A PREROUTING \
                 --destination <PUBIP> -m tcp --destination-port <PUBPORT> \
                 --jump DNAT --to-destination <PRIVATEIP>:<PRIVATEPORT>
seems to be what you need.

Reply to: