apache +tomcat 橋接

wangzhensheng發表於2007-03-16

# apache
./configure --prefix=/home/www --enable-so

#生成mod_jk.so檔案
./configure --with-apxs=/home/www/bin/apxs --enable-EAPI

[@more@]

# apache
./configure --prefix=/home/www --enable-so

#生成mod_jk.so檔案
./configure --with-apxs=/home/www/bin/apxs --enable-EAPI

# httpd.conf
LoadModule jk_module modules/mod_jk.so
#AddModule mod_jk.c
#
# Mod_jk settings
#

JkWorkersFile "conf/workers.properties"
JkLogFile "logs/mod_jk.log"

JkLogLevel error

JkMount /*.jsp default
JkMount /*.do default

#logs

LogFormat "%h %l %u %{[%Y/%m/%d/%w:%H:%M:%S]}t "%r" %>s %b "%{User-agent}i"" combined

CustomLog "|/usr/local/sbin/cronolog /app/www/logs/web-%Y%m%d.log" combined

=================================================================
# workers.properties
wndex.jsporkers.tomcat_home=/home/tomcat4
workers.java_home=$JAVA_HOME
ps=/
worker.list=default

worker.default.port=8009
worker.default.host=localhost
worker.default.type=ajp13
worker.default.lbfactor=1

==========================

# TOMCAT 配置
ln -s /usr/local/j2sdk1.4.2_08 /usr/java
cd /usr/bin/
mv java java.old
ln -s /usr/java/bin/java /usr/bin/java

# TOMCAT .bash_profile
JAVA_HOME=/usr/java

# tomcat記憶體設定
JAVA_OPTS='-Xms256m -Xmx512m'
# CATALINA_OPTS='-Xms256m -Xmx512m'

# java 畫筆

#CATALINA_OPTS='-Djava.awt.headless=true'

#ms是最小的,mx是最大,64m, 512m分別是指記憶體的容量.

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/8806316/viewspace-905397/,如需轉載,請註明出處,否則將追究法律責任。

相關文章