Re: Forward Specific Ports to Different Host/IP

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

 




Hi, 
try this for web server ...


iptables -t nat -A PREROUTING -s any/0 -d
your_external_ipadress -p tcp --dport 80 -j DNAT
--to-destination your_internal_ipaddress

Regards 

Elvir Kuric

PS: In this case we assume that your server in
internal network is listening on port 80. If in your
case it is not true, the you should use
your_internal_ipaddress:PORT_SERVER_LISTENING


--- Ranjith Kumar <ranjitbat@xxxxxxxxx> wrote:

> Hi All,
> 
> I have two linux machinces. I want to forward
> specific ports from
> mahince1 to machine2.
> 
> Machine1: Having 2 Network Interfaces, One interface
> is connected to
> the Internet with Static IP, and the second one is
> private IP
> connected to LAN.
> 
> Machine2: Having 1 Network Interface configured with
> private IP. This
> host is my mail server(postfix).
> 
> I am using Machine1 as relayhost. All my local users
> are accessing
> their mails from Machine2.
> 
> I want to Forward POP3, IMAP and HTTP ports from
> Machine1 to Machine2,
> when my users access mails from internet.
> 
> Please Help me in this.
> 
> Thanks & Regards,
> Ranjith Kumar
> 
> 


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


[Index of Archives]     [Linux Netfilter Development]     [Linux Kernel Networking Development]     [Netem]     [Berkeley Packet Filter]     [Linux Kernel Development]     [Advanced Routing & Traffice Control]     [Bugtraq]

  Powered by Linux