Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

In our server machine, we have two server software: Apache on port 80 and Weblogic on port 7001.

We want to redirect all requests coming to Apache under the subdirectory TRACDISWEB http://x.x.x.x/TRACDISWEB/ to http://x.x.x.x:7001/TRACDISWEB/

How can I do this?

Update:

In another similar question someone asked the following redirection:

jira.mydomain.com to jira.mydomain.com:8181

The accepted answer is this:

<VirtualHost jira.mydomain.com:*>
ProxyPreserveHost On
ProxyPass / http://jira.mydomain.com:8181/
ProxyPassReverse / http://jira.mydomain.com:8181/
ServerName jira.mydomain.com
</VirtualHost>

So, taking this as an example, should I write something like this:

<VirtualHost x.x.x.x:7001/TRACDISWEB/*>
ProxyPreserveHost On
ProxyPass / http://x.x.x.x:7001/TRACDISWEB/
ProxyPassReverse / http://x.x.x.x:7001/TRACDISWEB/
</VirtualHost>
share|improve this question

2 Answers 2

So, taking this as an example, should I write something like this:

no, it should be written like

<VirtualHost x.x.x.x:80>
   ProxyPreserveHost On
   ProxyRequests Off

   ProxyPass /TRACDISWEB/ http://x.x.x.x:7001/TRACDISWEB/
   ProxyPassReverse /TRACDISWEB/ http://x.x.x.x:7001/TRACDISWEB/
   ...
</VirtualHost>
share|improve this answer

Try looking into Apache's mod_proxy and the proxypass functionality.

share|improve this answer

Your Answer

 
discard

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.