日期:2014-05-16  浏览次数:20628 次

APACHE+RESIN负载均衡-----------------之apache部分

安装apache
./configure --prefix=/opt/apache2 --enable-so??--enable-dav --enable-dav-fs --enable-mods-shared=most??

make

make install

安装resin :

./configure --prefix=/opt/resin3.1.6 --with-apxs=/opt/apache2/bin/apxs??--with-apache=/opt/apache2

make

make install

上述操作编译安装完后,会自动修改apache,包括:

1.copy mod_caucho.soapache目录(就是前面指定的--with-apache=/data/aoxj/artest/apache)的modules

2. 修改apache的配置文件conf/httpd.conf,自动增加以下内容

LoadModule caucho_module ***/modules/mod_caucho.so

ResinConfigServer localhost 6800

CauchoConfigCacheDirectory /tmp

CauchoStatus yes

?

访问 http://localost/caucho-status 看是否成功.
如果访问不了。接着添加如下配置到httpd.conf中。
<Location /caucho-status>
??????? SetHandler caucho-status
</Location>

LoadModule caucho_module modules/mod_caucho.so

#ResinConfigServer localhost 6800

CauchoConfigCacheDirectory /tmp

CauchoStatus yes

<Location /caucho-status>
??????? SetHandler caucho-status
</Location>