httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ian Huynh" <i...@hubspan.com>
Subject RE: [users@httpd] RewriteRule problems
Date Tue, 14 Jun 2005 17:08:02 GMT
what does your rewrite log file say? If you add 

RewriteEngine on    
RewriteLog "/usr/local/var/apache/logs/rewrite.log"    <<--- change this to your appropriate
path
RewriteLogLevel 9                                       <<-- use level 9 only for debugging.
RewriteRule ^/old/(.*) http://ukrbcsr01/$1 [P]         <<-- make sure you don't pick
up the next rules, i'd use [P,L]


if the proxy was success, you would see something like this in your rewrite log

127.0.0.1 - - [06/Jun/2005:10:20:56 --0700] [localhost/sid#23c458][rid#82fa40/initial] (3)
applying pattern '^/old/(.*)' to uri '/old/something'
127.0.0.1 - - [06/Jun/2005:10:20:56 --0700] [localhost/sid#23c458][rid#82fa40/initial] (2)
rewrite /old/something -> http://ukrbcsr01/something
127.0.0.1 - - [06/Jun/2005:10:20:56 --0700] [localhost/sid#23c458][rid#82fa40/initial] (2)
forcing proxy-throughput with http://ukrbcsr01/something



-----Original Message-----
From: Arne Heizmann [mailto:Arne.Heizmann@csr.com]
Sent: Tuesday, June 14, 2005 9:46 AM
To: users@httpd.apache.org
Subject: [users@httpd] RewriteRule problems



Hi,

I get a 403 Forbidden when trying to use a RewriteRule to proxy a 
request to another server.

I have two servers, ukrbcsr01 and ukrbcsr02. ukrbcsr02 is accessible 
from the outside, ukrbcsr01 isn't. Their LAN IPs are 192.168.0.131 and 
192.168.0.132, respectively. I can access one from the other, so I know 
that both Apaches are running correctly and the LAN is working.

Now I added the following RewriteRule to ukrbcsr02:

	RewriteEngine On
	RewriteRule ^/old/(.*) http://ukrbcsr01/$1 [P]

I was hoping that [P] would work to proxy the request to the other 
server, but what I get instead is a 403 Forbidden when I try to access 
/old/something. I get the same 403 even when I stop the Apache on 
ukrbcsr01, so it must be ukrbcsr02 that generates the Forbidden message 
without even attempting to proxy the request.

Thanks for any advice you can give.
Arne Heizmann


**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.

**********************************************************************


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message