You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Mauricio Nuñez <ma...@chile.com> on 2005/07/28 22:43:55 UTC
Cluster threads
Hello!
I'm using 2 balanced tomcat , and , monitoring via JMX, I get the
following:
Tomcat1 : 4229 started thread, peak 123, live 118
Tomcat2 : 258 started thread, peak 89,line 86
Tomcat1 is my first tomcat started.
Tomcat2 get the sessions from Tomcat1.
The uptime is about 5 hours.
The started thread at Tomcat1 is linearly incrementaly. It's a normal
behavior?
The configuration used in both Tomcats is the following:
<Host name="localhost" appBase="webapps" >
<Cluster className="org.apache.catalina.cluster.tcp.SimpleTcpCluster"
managerClassName="org.apache.catalina.cluster.session.DeltaManager"
expireSessionsOnShutdown="false"
useDirtyFlag="false"
notifyListenersOnReplication="true">
<Membership
className="org.apache.catalina.cluster.mcast.McastService"
mcastAddr="228.0.0.4"
mcastPort="45564"
mcastFrequency="1000"
mcastDropTime="30000" />
<Receiver
className="org.apache.catalina.cluster.tcp.ReplicationListener"
tcpListenAddress="10.0.0.88"
tcpListenPort="4001"
tcpSelectorTimeout="100"
tcpThreadCount="6" />
<Sender
className="org.apache.catalina.cluster.tcp.ReplicationTransmitter"
replicationMode="pooled"
autoConnect="true"
waitForAck="true"
sendAllSessions="false"
sendAllSessionsSize="100"
compress="true"
ackTimeout="15000"/>
<Valve className="org.apache.catalina.cluster.tcp.ReplicationValve"
filter=".*\.gif;.*\.js;.*\.jpg;.*\.png;.*\.htm;.*\.html;.*\.css;.*\.txt;"/>
<!--Deployer className="org.apache.catalina.cluster.deploy.FarmWarDeployer"
tempDir="/tmp/war-temp/"
deployDir="/tmp/war-deploy/"
watchDir="/tmp/war-listen/"
watchEnabled="false"/ -->
</Cluster>
</Host>
Thanks
Mauricio Nuñez
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
Re: Cluster tcpThreadCount
Posted by Peter Rossbach <pr...@objektpark.de>.
Hey,
Use the 5.5.9 with cluster fix pack for fastasyncqueue cluster mode.
Yes, you can use the default config, but
change the ackTimeout to 45000 when you have heavy load and big session
replicated messages.
At 5.5.11 I have change a lot inside the cluster implementation, but
this version is currently an alpha release.
Peter
Randy Paries schrieb:
>Thanks for the response.
>
>What version was fastasyncqueue implemented? I am still running
>jakarta-tomcat-5.0
>
>There are so many different values
>
>Is this a good default to start with (from the doc page)??
>
><Sender
>className="org.apache.catalina.cluster.tcp.ReplicationTransmitter"
> replicationMode="fastasyncqueue"
> doTransmitterProcessingStats="true"
> doProcessingStats="true"
> doWaitAckStats="true"
> queueTimeWait="true"
> queueDoStats="true"
> queueCheckLock="true"
> ackTimeout="15000"
> waitForAck="true"
> keepAliveTimeout="80000"
> keepAliveMaxRequestCount="-1"/>
>
>
>-----Original Message-----
>From: Peter Rossbach [mailto:pr@objektpark.de]
>Sent: Saturday, August 27, 2005 1:41 AM
>To: Tomcat Users List
>Subject: Re: Cluster tcpThreadCount
>
>Hey Randy,
>
> tcpThreadCount is the number of parallel NIO receiver threads. Every tomcat
>cluster node with pooled mode has
>25 sender threads (Default). Normally two receiver thread per backup node
>are calc. More recevier worker means that you produce more load for
>replication at backup!
>At heavy loaded site I use only the fastasyncqueue mode. This mode has at
>my test case better performance and more guaranty that replication works
>well. You can also switch to the domain cluster model.
>Install more nodes with different backup domainnodes.
>
>Example
>
>Apache 1 and four tomcats
>
>T01 and T03 are inside domain A ( same mcast port)
>T02 and T04 are inside domain B ( same mcast port)
>
>T01 and T02 living at box B1
>T03 and T04 living at box B2
>
>Peter
>
>PS: When you used tomcat 5.5.9 don't forget to install the cluster fix pack
>( s. bugzilla)
>
>
>Randy Paries schrieb:
>
>
>
>>Hello,
>>
>>How do I determine what value I should set tcpThreadCount to
>>
>>Currently I have the setting below and a very busy app server.
>>
>>Thanks
>>Randy
>>
>><Receiver className="org.apache.catalina.cluster.tcp.ReplicationListener"
>> tcpListenAddress="10.0.0.88"
>> tcpListenPort="4001"
>> tcpSelectorTimeout="100"
>> tcpThreadCount="6" />
>>
>><Sender className="org.apache.catalina.cluster.tcp.ReplicationTransmitter"
>> replicationMode="pooled"
>> autoConnect="true"
>> waitForAck="true"
>> sendAllSessions="false"
>> sendAllSessionsSize="100"
>> compress="true"
>> ackTimeout="15000"/>
>>
>>
>>
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>>For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>>
>>
>>
>>
>>
>>
>>
>>
>
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>
>
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>
>
>
>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
RE: Cluster tcpThreadCount
Posted by Randy Paries <ra...@unitnet.com>.
Thanks for the response.
What version was fastasyncqueue implemented? I am still running
jakarta-tomcat-5.0
There are so many different values
Is this a good default to start with (from the doc page)??
<Sender
className="org.apache.catalina.cluster.tcp.ReplicationTransmitter"
replicationMode="fastasyncqueue"
doTransmitterProcessingStats="true"
doProcessingStats="true"
doWaitAckStats="true"
queueTimeWait="true"
queueDoStats="true"
queueCheckLock="true"
ackTimeout="15000"
waitForAck="true"
keepAliveTimeout="80000"
keepAliveMaxRequestCount="-1"/>
-----Original Message-----
From: Peter Rossbach [mailto:pr@objektpark.de]
Sent: Saturday, August 27, 2005 1:41 AM
To: Tomcat Users List
Subject: Re: Cluster tcpThreadCount
Hey Randy,
tcpThreadCount is the number of parallel NIO receiver threads. Every tomcat
cluster node with pooled mode has
25 sender threads (Default). Normally two receiver thread per backup node
are calc. More recevier worker means that you produce more load for
replication at backup!
At heavy loaded site I use only the fastasyncqueue mode. This mode has at
my test case better performance and more guaranty that replication works
well. You can also switch to the domain cluster model.
Install more nodes with different backup domainnodes.
Example
Apache 1 and four tomcats
T01 and T03 are inside domain A ( same mcast port)
T02 and T04 are inside domain B ( same mcast port)
T01 and T02 living at box B1
T03 and T04 living at box B2
Peter
PS: When you used tomcat 5.5.9 don't forget to install the cluster fix pack
( s. bugzilla)
Randy Paries schrieb:
>Hello,
>
>How do I determine what value I should set tcpThreadCount to
>
>Currently I have the setting below and a very busy app server.
>
>Thanks
>Randy
>
><Receiver className="org.apache.catalina.cluster.tcp.ReplicationListener"
> tcpListenAddress="10.0.0.88"
> tcpListenPort="4001"
> tcpSelectorTimeout="100"
> tcpThreadCount="6" />
>
><Sender className="org.apache.catalina.cluster.tcp.ReplicationTransmitter"
> replicationMode="pooled"
> autoConnect="true"
> waitForAck="true"
> sendAllSessions="false"
> sendAllSessionsSize="100"
> compress="true"
> ackTimeout="15000"/>
>
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>
>
>
>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
Re: Cluster tcpThreadCount
Posted by Peter Rossbach <pr...@objektpark.de>.
Hey Randy,
tcpThreadCount is the number of parallel NIO receiver threads. Every
tomcat cluster node with pooled mode has
25 sender threads (Default). Normally two receiver thread per backup
node are calc. More recevier worker means that
you produce more load for replication at backup!
At heavy loaded site I use only the fastasyncqueue mode. This mode has
at my test case
better performance and more guaranty that replication works well. You
can also switch to the domain cluster model.
Install more nodes with different backup domainnodes.
Example
Apache 1 and four tomcats
T01 and T03 are inside domain A ( same mcast port)
T02 and T04 are inside domain B ( same mcast port)
T01 and T02 living at box B1
T03 and T04 living at box B2
Peter
PS: When you used tomcat 5.5.9 don't forget to install the cluster fix
pack ( s. bugzilla)
Randy Paries schrieb:
>Hello,
>
>How do I determine what value I should set tcpThreadCount to
>
>Currently I have the setting below and a very busy app server.
>
>Thanks
>Randy
>
><Receiver className="org.apache.catalina.cluster.tcp.ReplicationListener"
> tcpListenAddress="10.0.0.88"
> tcpListenPort="4001"
> tcpSelectorTimeout="100"
> tcpThreadCount="6" />
>
><Sender className="org.apache.catalina.cluster.tcp.ReplicationTransmitter"
> replicationMode="pooled"
> autoConnect="true"
> waitForAck="true"
> sendAllSessions="false"
> sendAllSessionsSize="100"
> compress="true"
> ackTimeout="15000"/>
>
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
>
>
>
>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
Cluster tcpThreadCount
Posted by Randy Paries <ra...@unitnet.com>.
Hello,
How do I determine what value I should set tcpThreadCount to
Currently I have the setting below and a very busy app server.
Thanks
Randy
<Receiver className="org.apache.catalina.cluster.tcp.ReplicationListener"
tcpListenAddress="10.0.0.88"
tcpListenPort="4001"
tcpSelectorTimeout="100"
tcpThreadCount="6" />
<Sender className="org.apache.catalina.cluster.tcp.ReplicationTransmitter"
replicationMode="pooled"
autoConnect="true"
waitForAck="true"
sendAllSessions="false"
sendAllSessionsSize="100"
compress="true"
ackTimeout="15000"/>
---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org