LVS
lvs-users
Google
 
Web LinuxVirtualServer.org

RE: rewrite rule like apache to hide port

To: <ychan@xxxxxxxxxx>,<lvs-users@xxxxxxxxxxxxxxxxxxxxxx>
Subject: RE: rewrite rule like apache to hide port
From: "Stephen Walker" <swalker@xxxxxxxxxxxxx>
Date: Tue, 19 Aug 2003 09:56:46 -0400
This is how I set up my reverse proxy in apache:

    ProxyRequests Off
    RewriteEngine On

    ProxyPass /perl http://www.abc.com:8080/perl

    RewriteRule (^.*\.pl) http://www.abc.com:8080$1 [proxy,last]
    RewriteRule (^.*\.cgi) http://www.abc.com:8080$1 [proxy,last]

    ProxyPassReverse / http://www.abc.com:8080/
    ProxyReceiveBufferSize 49152

The ProxyPass rule says everything that goes to /perl is forwarded to
port 8080, the Rewrite rules take care of scripts ending in .pl or .cgi.
Obviously you need to have the rewrite and proxy modules running on your
apache server.

HTH,
Steve

-----Original Message-----
From: lvs-users-bounces@xxxxxxxxxxxxxxxxxxxxxx
[mailto:lvs-users-bounces@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of Yan Chan
Sent: Tuesday, August 19, 2003 9:31 AM
To: lvs-users@xxxxxxxxxxxxxxxxxxxxxx
Subject: rewrite rule like apache to hide port


Hi all,

My ipvs is set up right and everything.  I set the VIP's address of port
80 to forward to my Real Web Servers.  I then set port 90 to another Web
Server with different stuff in it.  My problem is when i try to access
the page for port 80, www.abc.com, the web page shows fine.  In order
for me to access the page in port 90, i have to type www.abc.com:90.  As
you can see, it doesnt look elegant.  Is there a way to change it so i
can make it www.abc.com/ipvs equal to www.abc.com:90?  like the rewrite
rule in apache?  I tried using apache in the loadbalancer. But it doesnt
seen to work.  Any idea?  thx

________________________________________________
Get your own "800" number
Voicemail, fax, email, and a lot more http://www.ureach.com/reg/tag
_______________________________________________
LinuxVirtualServer.org mailing list - lvs-users@xxxxxxxxxxxxxxxxxxxxxx
Send requests to lvs-users-request@xxxxxxxxxxxxxxxxxxxxxx
or go to http://www.in-addr.de/mailman/listinfo/lvs-users

<Prev in Thread] Current Thread [Next in Thread>