httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Cameron Beattie" <>
Subject [users@httpd] RewriteRule question: forward requests from one Apache server to another
Date Tue, 28 Jun 2005 02:49:47 GMT
I am trying to set up the following configuration:
1. Apache server with public IP address
2. Apache server behind NAT with no public IP address
3. Router with public IP address with port forwarding set up for port 8008 
to Apache server 2
4. Public DNS record resolves to IP address of server 1

When a user browses to I want a web site to be served up 
from from server 2.

I have set the following up in httpd.conf on server 1:
<VirtualHost *:80>
        RewriteEngine On
        RewriteRule ^/(.*) http://60.234.nnn.nn:8008/$1 [L,P]

I have set the following up in httpd.conf on server 2:
<VirtualHost *:8008>
    DocumentRoot /var/www/html

I can access the website locally by accessing the site on server 2, but not 
through server 1. If I enter I just get the 
default apache homepage, rather than the index.phtml page that I want to be 
served up. If I enter I get a 404 

I guess my rewriterule is wrong but I'm not sure how to fix it. Any help 
would be appreciated.



The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message