Sharing the Point

Office 365, SharePoint, Project Server – Support Blog

How to Redirect all Apache 2.x Request to Tomcat 6.x.x using mod_proxy Module

Posted by Ashraf on January 2, 2011

Consider: Apache 2.x is running on port 80, Tomcat 6.x.x is on port 8080

  1. Got to {Apche2 installation folder}\Apache2.2\conf , Open httpd.conf to edit
  2. Uncomment the following three lines,
    1. LoadModule proxy_module modules/
    2. LoadModule proxy_ajp_module modules/
    3. LoadModule proxy_balancer_module modules/
  3. Add the following entry to the main section of httpd.conf file

      #Enableing proxy for rediretion to tomcat

      ProxyRequests Off

      ProxyPreserveHost On

      <Proxy *>

      Order deny,allow

      Allow from all


      ProxyPass / ajp://localhost:8009/

      ProxyPassReverse / ajp://localhost:8009/

      <Location / >

      Order allow,deny

      Allow from all


  4. Test by typing http://localhost; tomcat default page will come up.

3 Responses to “How to Redirect all Apache 2.x Request to Tomcat 6.x.x using mod_proxy Module”

  1. Raja said

    Awesome post Ashraf! This saved me a ton of time.

  2. dskanth said

    Great post… i just want to know, how can i pass the request to the Tomcat server and then get the response back to my Apache page?

  3. dskanth said

    Good post…. but how do i redirect a request to Tomcat and then get back the response to Apache page?

Sorry, the comment form is closed at this time.

%d bloggers like this: