欢迎来到天天文库
浏览记录
ID:39468907
大小:57.00 KB
页数:16页
时间:2019-07-04
《tomcat-connector安装》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、前不久整合过apache+tomcat,拿出来供LZ参考运行环境: OS :ubuntu7.10 gcc:4.1.3 jdk:1.5.0_14 apache:2.2.6 tomcat:5.5.26 1.安装前准备:到Apache官方网站下载所需要的文件,httpd-2.2.6.tar.gz,mod_jk-1.2.26-httpd-2.2.6.so (Gcc,JDK自行安装) 2.安装apache #tarzxvfhttpd-2.2.6.tar.gz
2、 #cdhttpd-2.2.6 ########--prefix为指定apache的安装路径(请按实际情况修改),其它项为预安装的模块,除了--enable-so项外,可指定其它模块以后再安装 #./configure--prefix=/home/tom/apache--enable-module=most--enable-proxy--enable-proxy-ajp--enable-forward--enable-proxy-connect-- enable-pr
3、oxy-http--enable-so--enable-deflate--enable-headers--enable-includ--enable-alias--enable-dbd--enable-disk-cache--enable-cache-- enable-file-cache --enable-info--enable-mem-cache --enable-status #make #makeinstall 3. 将mod_jk-1.2.26-httpd-2.2.
4、6.so放到apache下的modules文件夹下,并改名为mod_jk.so 4.配置 在apache/conf/下面建立两个配置文件mod_jk.conf和workers.properties。 #vimod_jk.conf 添加以下内容: #指出mod_jk模块工作所需要的工作文件workers.properties的位置 JkWorkersFile/usr/local/apache2/conf/workers.properties
5、 (需要根据实际情况修改) #Wheretoputjklogs JkLogFile/usr/local/apache2/logs/mod_jk.log (需要根据实际情况修改) #Setthejkloglevel[debug/error/info] JkLogLevelinfo #Selectthelogformat JkLogStampFormat"[%a%b%d%H:%M:%S%
6、Y]" #JkOptionsindicatetosendSSLKEYSIZE, JkOptions+ForwardKeySize+ForwardURICompat-ForwardDirectories #JkRequestLogFormatsettherequestformat JkRequestLogFormat"%w%V%T" #将所有servlet和jsp请求通过ajp13的协议送给Tomcat,让Tomcat来处理
7、 JkMount/servlet/*worker1 JkMount/*.jspworker1 #viworkers.properties 添加以下内容: #Definingaworkernamedworker1andoftypeajp13 worker.list=worker1 #Setpropertiesforworker1 worker.worker1.type=ajp13 wo
8、rker.worker1.host=localhost (此项为tomcat服务器地址) worker.worker1.port=8009 worker.worker1.lbfactor=50 worker.worker1.cach
此文档下载收益归作者所有