apache2.2 + tomcat 5.0 by JK_mod

1.下载mod_jk-apache-2.2.2.so,放入D:/Program Files/Apache Software Foundation/Apache2.2/modules目录下
 
2.修改Tomcat的conf/server.xml :
在<Engine name="Catalina" defaultHost="localhost" debug="0">下面加一句
 <listener classname="org.apache.jk.config.ApacheConfig" modjk="D:/Program Files/Apache Software Foundation/Apache2.2/modules/mod_jk-

apache-2.2.2.so"/>
 
3.在apache安装目录下的conf目录中创建workers.properties文件,内容如下
 
workers.apache_log=D:/Program Files/Apache Software Foundation/Apache2.2/logs
workers.tomcat_home=D:/Tomcat 5.0
ps=# the list of workers
worker.list=ajp13
# worker "ajp13" will talk to Tomcat listening on machine localhost at port 8009 using 3 lb factor
worker.ajp13.type=ajp13
worker.ajp13.host=localhost
worker.ajp13.port=8009
worker.ajp13.lbfactor=3
# worker "ajp13" use up to 10 sockets, which will stay no more than 10mn in cache
worker.ajp13.cachesize=10
worker.ajp13.cache_timeout=600
# worker "ajp13" ask operating system to send KEEP-ALIVE signal on the connection
worker.ajp13.socket_keepalive=1
# worker "ajp13" want ajp13 connection to be dropped after 5mn (recycle)
worker.ajp13.recycle_timeout=300
# Define the LB worker
worker.router.type=lb
worker.router.balance_workers=ajp13
# Add the status worker to the worker list
worker.list=jkstatus
# Define a 'jkstatus' worker using status
worker.jkstatus.type=status
# Add the jkstatus mount point
JkMount /jkmanager/* jkstatus
# Enable the JK manager access from localhost only
<location>
JkMount jkstatus
Order deny,allow
Deny from all
Allow from 127.0.0.1
</location>

 
4.修改apache的conf/httpd.conf文件:
 
在文件最后加入
 
LoadModule jk_module "modules/mod_jk-apache-2.2.2.so"
JkWorkersFile "D:/Program Files/Apache Software Foundation/Apache2.2/conf/workers.properties"
JkLogFile "D:/Tomcat 5.0/logs/mod_jk.log"
JkLogLevel info
JkMount /servlet/* ajp13
JkMount /*.jsp ajp13
Alias /kms "D:/Tomcat 5.0/webapps/kms"
<Directory "D:/Tomcat 5.0/webapps/kms">
Options Indexes MultiViews
AddOutputFilter Includes html
AllowOverride None
Order allow,deny
Allow from all
</Directory>
 
 
5. 重启 apache和tomcat ,访问http://localhost/kms 即可
 

 

from:http://tb.blog.csdn.net/TrackBack.aspx?PostId=1155586

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值