Redirect Apache 2.x Request to Tomcat 7.x.x using mod_proxy Module
After installing Linux by default make Apache 2.x to run on port 80 and run Tomcat 7.x.x on port 8080
Now go to Apche2 installation folder\Apache2.2\conf folder. Open httpd.conf to Uncomment the following three lines,
- LoadModule proxy_module modules/mod_proxy.so
- LoadModule proxy_ajp_module modules/mod_proxy_ajp.so
- LoadModule proxy_balancer_module modules/mod_proxy_balancer.so
Look for the lineand uncomment it.
Add the following entry into the above section of httpd.conf file
ProxyRequests Off
ProxyPreserveHost On
<Proxy *>
Order deny,allow
Allow from all
</Proxy>
ProxyPass / ajp://localhost:8009/
ProxyPassReverse / ajp://localhost:8009/
<Location / >
Order allow,deny
Allow from all
</Location>
It’s Done. Now by typing http://localhost; tomcat default page will come up.
What is Proxy ?
Benefits of using Apache as Proxy
Filed under: OMNI Installation