Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

We have reverse web proxy on Apache2 that proxies requests to the remote webserver using URL http://server1 that gets content proxied from http://realserver1
Now I am trying to add another site to webproxy that does the same, the difference is that remote server already runs Apache as a reverse proxy (for the java application on the same host but different port).
I.e. webproxy serves URL http://server2 that gets content proxied from http://realserver2, which in turn gets its content from http://localhost:someport
Now I would expect that this setup would just work, however it does not. Instead I am being redirected to http://realserver2.Any idea what ai am doing wrong? Thank you!

Code can be seen in

share|improve this question

Check that you have a ProxyPassReverse directive for each ProxyPass already in place.

Check that you're not performing any erroneous rewrites (with flag R in particular) or standard redirections on realserver2.

Also: post the relevant bits of configuration so we can have a look at them.

share|improve this answer
sorry – Sergei May 20 '11 at 13:47
up vote 0 down vote accepted

adding follwing in webproxy fixed it
ProxyPreserveHost On

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.