* Redirect my internat web server
@ 2003-01-17 18:06 Hélio Dubeux
2003-01-18 16:23 ` Andrea Rossato
2003-01-20 7:01 ` Paulo Andre
0 siblings, 2 replies; 3+ messages in thread
From: Hélio Dubeux @ 2003-01-17 18:06 UTC (permalink / raw)
To: netfilter
I have a machine with squid + nat with an valid ip (1.1.1.1) and a false ip
(2.2.2.2) and running apache on port 80, i want to publish another apache
server on port 8000 in a machine with ip (3.3.3.3). how can i do this
redirect? I´ve already used:
iptables -A PREROUTING -t nat -p tcp -d 1.1.1.1 --dport 8000 -j DNAT -to
3.3.3.3:8000
My clients type on their browser http://1.1.1.1:8000 and i wanto to show the
content of 3.3.3.3:8000
Anyone can plz help me?
----------------------
Hélio Dubeux Neto
_________________________________________________________________
MSN Hotmail, o maior webmail do Brasil. http://www.hotmail.com
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Redirect my internat web server
2003-01-17 18:06 Redirect my internat web server Hélio Dubeux
@ 2003-01-18 16:23 ` Andrea Rossato
2003-01-20 7:01 ` Paulo Andre
1 sibling, 0 replies; 3+ messages in thread
From: Andrea Rossato @ 2003-01-18 16:23 UTC (permalink / raw)
To: netfilter
iptables -A PREROUTING -t nat -p tcp -d 1.1.1.1 --dport 8000 -j DNAT -to
3.3.3.3
iptables -t nat -A POSTROUTING -d 3.3.3.3 --dport 8000 -j SNAT
--to-source 1.1.1.1
that should be enough.
regards,
andrea
Hélio Dubeux wrote:
> I have a machine with squid + nat with an valid ip (1.1.1.1) and a false
> ip (2.2.2.2) and running apache on port 80, i want to publish another
> apache server on port 8000 in a machine with ip (3.3.3.3). how can i do
> this redirect? I´ve already used:
>
> iptables -A PREROUTING -t nat -p tcp -d 1.1.1.1 --dport 8000 -j DNAT -to
> 3.3.3.3:8000
>
> My clients type on their browser http://1.1.1.1:8000 and i wanto to show
> the content of 3.3.3.3:8000
>
> Anyone can plz help me?
>
>
> ----------------------
> Hélio Dubeux Neto
>
>
>
>
> _________________________________________________________________
> MSN Hotmail, o maior webmail do Brasil. http://www.hotmail.com
>
>
>
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Redirect my internat web server
2003-01-17 18:06 Redirect my internat web server Hélio Dubeux
2003-01-18 16:23 ` Andrea Rossato
@ 2003-01-20 7:01 ` Paulo Andre
1 sibling, 0 replies; 3+ messages in thread
From: Paulo Andre @ 2003-01-20 7:01 UTC (permalink / raw)
To: Hélio Dubeux; +Cc: netfilter
On Fri, 2003-01-17 at 20:06, Hélio Dubeux wrote:
> I have a machine with squid + nat with an valid ip (1.1.1.1) and a false ip
> (2.2.2.2) and running apache on port 80, i want to publish another apache
> server on port 8000 in a machine with ip (3.3.3.3). how can i do this
> redirect? I´ve already used:
>
> iptables -A PREROUTING -t nat -p tcp -d 1.1.1.1 --dport 8000 -j DNAT -to
> 3.3.3.3:8000
>
> My clients type on their browser http://1.1.1.1:8000 and i wanto to show the
> content of 3.3.3.3:8000
>
> Anyone can plz help me?
>
The PREROUTING seems fine, just remember to also add a FORWARD rule to
allow the packet to be 'forwarded' to 3.3.3.3
Paulo
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2003-01-20 7:01 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-01-17 18:06 Redirect my internat web server Hélio Dubeux
2003-01-18 16:23 ` Andrea Rossato
2003-01-20 7:01 ` Paulo Andre
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox