-
Configuring Apache Web Server with Tomcat (1 messages)
- Posted by: Muhammad Ali Amin
- Posted on: July 15 2009 07:39 EDT
I am trying to configuring apache webserver with tomcat using AJP but i am not sure am i doing it right or not. Here are the steps that i followed * Enabled required module in httpd.conf file LoadModule proxy_module modules/mod_proxy.so LoadModule proxy_ajp_module modules/mod_proxy_ajp.so * Added the ifModule condition in httpd.conf file ProxyPass / ajp://localhost:8009/ ProxyPassReverse / ajp://localhost:8009/ ProxyPassMatch ^(/photos/.*\.jpg)$! Alias /photos "F:\projects\AL\Photos" Options Indexes MultiViews AllowOverride None Order allow,deny Allow from all * And finally adding the connector in server.xml file of tomcat Now i am trying to test to browse some JSP file at the following location http://localhost:8009/examples/jsp/jsp2/el/basic-arithmetic.jsp which is working fine. but i want to browse this file at http://localhost/examples/jsp/jsp2/el/basic-arithmetic.jsp. Have i done it right or there is something else that i can do?Threaded Messages (1)
- Re: Configuring Apache Web Server with Tomcat by Sergei Batiuk on October 01 2009 08:20 EDT
-
Re: Configuring Apache Web Server with Tomcat[ Go to top ]
- Posted by: Sergei Batiuk
- Posted on: October 01 2009 08:20 EDT
- in response to Muhammad Ali Amin
Another way to integrate HTTPD with Tomcat is to use the mod_jk module. You need to do the following: HTTPD configuration: - Add the mod_jk reference in httpd.conf (we do this typically in a separate file) LoadModule jk_module modules/mod_jk.so JkShmFile locks/mod_jk/mod_jk.shm JkLogFile logs/mod_jk.log JkLogLevel info JkWorkersFile conf/jk_workers.properties - Describe a worker for your tomcat in the jk_workers.properties file: worker.list=myworker worker.myworker.type=ajp13 worker.myworker.host=localhost worker.myworker.port=8009 - Map requests to your worker: JkMount /* myworker Tomcat configuration: - In the server.xml file enable the AJP connector: Java Development on Demand http://www.hitech.com.ua/en/