the two tomcat are on different machines, one is on the same server with
apache.

2009/8/10 Filip Hanik - Dev Lists <devli...@hanik.com>

> are the Tomcat machines on the same box?
> if yes, and this is tomcat 6.0.20, there is a regression in the tomcat code
> https://issues.apache.org/bugzilla/show_bug.cgi?id=47308
>
> If this is not the case, let us know and we can help you further
> Filip
>
>
> On 08/10/2009 05:51 AM, TianJing wrote:
>
>> Hi all,
>>
>> i am now setting up a cluster with a  httpd-2.2.13 and two tomcat 6.0, i
>> hope to use Session Replication,but there have some problems:
>> the session can not replication,when a tomcat is disappeared, the session
>> is
>> lost.
>>
>> could you please give me some advices? thanks very much!
>>
>> here is some detail information:
>>
>> i set the cluser at engine level,and my routing table is :
>> Destination     Gateway         Genmask         Flags Metric Ref    Use
>> Iface
>> 255.255.255.255 0.0.0.0         255.255.255.255 UH    0      0        0
>> eth0
>> 224.0.0.4       0.0.0.0         255.255.255.255 UH    0      0        0
>> eth1
>>
>>
>> my configure file is as follow:
>>
>>
>> ########workers.properties configuration
>> workers.java_home=/usr/java/latest
>> worker.list=controller
>> # Set properties for worker1;
>> worker.worker1.type=ajp13
>> worker.worker1.host=localhost
>> worker.worker1.port=8999
>> worker.worker1.lbfactor=50
>> worker.worker1.cachesize=10
>> worker.worker1.cache_timeout=600
>> worker.worker1.socket_keepalive=1
>> worker.worker1.socket_timeout=300
>> worker.worker1.redirect=worker2
>> # Set properties for worker2;
>> worker.worker2.type=ajp13
>> worker.worker2.host=192.168.8.129
>> worker.worker2.port=8999
>> worker.worker2.lbfactor=50
>> worker.worker2.cachesize=10
>> worker.worker2.cache_timeout=600
>> worker.worker2.socket_keepalive=1
>> worker.worker2.socket_timeout=300
>> worker.worker2.redirect=worker1
>> # Define the LB worker
>> worker.controller.type=lb
>> worker.controller.balance_workers=worker1,worker2
>> worker.controller.sticky_session=true
>>
>> ########apache vhost:
>> <VirtualHost *:80>
>>     ServerAdmin xxxx.xxxx.xxxx
>>     #DocumentRoot "/share/bccdata/Cloud/src"
>>     DirectoryIndex  home.xhtml index.htm index.jsp index.php
>>     ServerName xxx.xxx.xxx.xxx
>>     JkMountFile /scratch/apache2.2.13/conf/worker.conf
>>     ErrorLog "logs/cloud-error.log"
>>     CustomLog "logs/cloud-access_log" common
>> </VirtualHost>
>>
>> #######worker.conf
>> /*=controller
>>
>>
>> ##tomcat1 server.xml on server1
>>     <Engine name="Catalina" defaultHost="xxx.xxxxx.xxx.xx"
>> jvmRoute="controller">
>>       <Realm className="org.apache.catalina.realm.UserDatabaseRealm"
>>              resourceName="UserDatabase"/>
>>         <Cluster className="org.apache.catalina.ha.tcp.SimpleTcpCluster"
>> channelSendOptions="8">
>>                 <!--<Manager
>> className="org.apache.catalina.ha.session.BackupManager"
>>                                  expireSessionsOnShutdown="false"
>>                                  notifyListenersOnReplication="true"
>>                                  mapSendOptions="6"/>-->
>>                 <Manager
>> className="org.apache.catalina.ha.session.DeltaManager"
>>                                  expireSessionsOnShutdown="false"
>>                                  notifyListenersOnReplication="true"/>
>>
>>                  <Channel
>> className="org.apache.catalina.tribes.group.GroupChannel">
>>                  <Membership
>> className="org.apache.catalina.tribes.membership.McastService"
>>                                          address="224.0.0.4"
>>                                          port="45564"
>>                                      frequency="500"
>>                                      dropTime="3000"/>
>>                  <Receiver
>> className="org.apache.catalina.tribes.transport.nio.NioReceiver"
>>                                    address="auto"
>>                                    port="4000"
>>                                selectorTimeout="100"
>>                                    maxThreads="6"/>
>>                  <Sender
>> className="org.apache.catalina.tribes.transport.ReplicationTransmitter">
>>                  <Transport
>>
>> className="org.apache.catalina.tribes.transport.nio.PooledParallelSender"/>
>>                  </Sender>
>>              <Interceptor
>>
>> className="org.apache.catalina.tribes.group.interceptors.TcpFailureDetector"/>
>>              <Interceptor
>>
>> className="org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor"/>
>>                  <Interceptor
>>
>> className="org.apache.catalina.tribes.group.interceptors.ThroughputInterceptor"/>
>>                  </Channel>
>>                  <Valve
>> className="org.apache.catalina.ha.tcp.ReplicationValve"
>>
>>
>> filter=".*\.gif;.*\.js;.*\.jpg;.*\.png;.*\.htm;.*\.html;.*\.css;.*\.txt;"/>
>>
>>         <Deployer
>> className="org.apache.catalina.ha.deploy.FarmWarDeployer"
>>                                   tempDir="/tmp/war-temp/"
>>                                   deployDir="/tmp/war-deploy/"
>>                                   watchDir="/tmp/war-listen/"
>>                                   watchEnabled="false"/>
>>                 <ClusterListener
>>
>> className="org.apache.catalina.ha.session.JvmRouteSessionIDBinderListener"/>
>>                 <ClusterListener
>> className="org.apache.catalina.ha.session.ClusterSessionListener"/>
>>             </Cluster>
>>   <Host name="xxx.xxx.xxx.xxx" debug="0" appBase="webapps"
>> unpackWARs="true"
>> autoDeploy="true">
>>     <Context path="" docBase="Test"  debug="0" reloadable="false"
>> distributable="true"/>
>>  </Host>
>>
>>     </Engine>
>>
>>
>> ##tomcat2 server.xml on server2
>>     <Engine name="Catalina" defaultHost="xxx.xxx.xxx.xxx"
>> jvmRoute="controller">
>>       <Realm className="org.apache.catalina.realm.UserDatabaseRealm"
>>              resourceName="UserDatabase"/>
>>     <!--<Engine name="Catalina" defaultHost="localhost">-->
>>
>>         <Cluster className="org.apache.catalina.ha.tcp.SimpleTcpCluster"
>> channelSendOptions="8">
>>                 <!--<Manager
>> className="org.apache.catalina.ha.session.BackupManager"
>>                                  expireSessionsOnShutdown="false"
>>                                  notifyListenersOnReplication="true"
>>                                  mapSendOptions="6"/>-->
>>                 <Manager
>> className="org.apache.catalina.ha.session.DeltaManager"
>>                                  expireSessionsOnShutdown="false"
>>                                  notifyListenersOnReplication="true"/>
>>
>>                  <Channel
>> className="org.apache.catalina.tribes.group.GroupChannel">
>>                 <Membership
>> className="org.apache.catalina.tribes.membership.McastService"
>>                                          address="224.0.0.4"
>>                                          port="45564"
>>                                      frequency="500"
>>                                      dropTime="3000"/>
>>                  <Receiver
>> className="org.apache.catalina.tribes.transport.nio.NioReceiver"
>>                                    address="auto"
>>                                    port="4000"
>>                                selectorTimeout="100"
>>                                    maxThreads="6"/>
>>                  <Sender
>> className="org.apache.catalina.tribes.transport.ReplicationTransmitter">
>>                  <Transport
>>
>> className="org.apache.catalina.tribes.transport.nio.PooledParallelSender"/>
>>                  </Sender>
>>              <Interceptor
>>
>> className="org.apache.catalina.tribes.group.interceptors.TcpFailureDetector"/>
>>              <Interceptor
>>
>> className="org.apache.catalina.tribes.group.interceptors.MessageDispatch15Interceptor"/>
>>                  <Interceptor
>>
>> className="org.apache.catalina.tribes.group.interceptors.ThroughputInterceptor"/>
>>                  </Channel>
>>                  <Valve
>> className="org.apache.catalina.ha.tcp.ReplicationValve"
>>
>>
>> filter=".*\.gif;.*\.js;.*\.jpg;.*\.png;.*\.htm;.*\.html;.*\.css;.*\.txt;"/>
>>
>>         <Deployer
>> className="org.apache.catalina.ha.deploy.FarmWarDeployer"
>>                                   tempDir="/tmp/war-temp/"
>>                                   deployDir="/tmp/war-deploy/"
>>                                   watchDir="/tmp/war-listen/"
>>                                   watchEnabled="false"/>
>>                 <ClusterListener
>>
>> className="org.apache.catalina.ha.session.JvmRouteSessionIDBinderListener"/>
>>                 <ClusterListener
>> className="org.apache.catalina.ha.session.ClusterSessionListener"/>
>>             </Cluster>
>>   <Host name="xxxx.xxx.xxx.xxx" debug="0" appBase="webapps"
>> unpackWARs="true" autoDeploy="true">
>>     <Context path="" docBase="Test"  debug="0" reloadable="false"
>> distributable="true"/>
>>  </Host>
>>
>>     </Engine>
>>
>>
>>
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
>
>


-- 
Tianjing

Bioinformatics Center,
Beijing Genomics Institute,Shenzhen
Tel:+86-755-25273851
MSN:tianjing...@hotmail.com <msn%3atianjing...@hotmail.com>

Reply via email to