[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: how to redirect web traffic to different server
So, it is not related to openbsd, but to apache (if apache
is your webserver). for apache though, look at mod_rewrite
you may define B to serve all request for http://mydomain
and add specific rules for /bss uri, to be forwarded (or proxy-ed)
to A. that's all.
> Maybe I misled you guys,
> I am runing two web server behind OBSD gateway on
> server A and B, I want all the access to
> http://mydomain/bbs/ to server A, and all other access
> (for example: http://mydomain/index.html) to server B,
> I don't want to use two port on gateway, and then use
> pf to redirect to different server, I just want to use
> the only one port 80, and redirect the different
> service to different server.
> --- "Christopher D. Palmer" <email@example.com> wrote:
> > On Tue, Feb 24, 2004 at 12:52:42AM -0800, Gavin Li
> > wrote:
> > > Hi,
> > >
> > > I have a OBSD gateway, and server OBSD machine
> > running
> > > in the local network, I want the gateway redirect
> > > different web access to different server.
> > > For example, I want all access to
> > > http://myserver.org/tech to OBSD machine A in
> > local
> > > network, all other access to machine B in local
> > > network.
> > > How can I setup my gateway to do this job? or do I
> > > need some software? I only have installed the base
> > > system without X.
> > > Thanks.
> > "PF: Redirection (Port Forwarding)"
> > "Let's look at an example:
> > rdr on tl0 proto tcp from any to any port 80 ->
> > 192.168.1.20
> > This line redirects TCP port 80 (web server) traffic
> > to a machine
> > inside the network at 192.168.1.20. So, even though
> > 192.168.1.20 is
> > behind your gateway and inside your network, the
> > outside world can
> > access it."
> > http://www.OpenBSD.org/faq/pf/rdr.html
> > --
> > Christopher D. Palmer
> Do you Yahoo!?
> Yahoo! Mail SpamGuard - Read only the mail you want.