Julio Cesar Leiva schrieb:
Hi all

We have  this setup

1 web server apache 2.2.0

I hope it's not 2.2.0 but something more recent (e.g. 2.2.4 or 2.2.6)

2 tomcat servers tomcat 5.5.20
mod_jk 1.2.25

This is our workers.properties

Remove the next line, it's useless.

workers.java_home=/usr/lib64/jvm/java

worker.list=cbnbalancer,jkstatus

Maybe add connect_timeout and prepost_timeout to the next two, and if it makes sense for the app also reply_timeout. See

http://tomcat.apache.org/connectors-doc/generic_howto/timeouts.html

# Set properties for worker1 (ajp13)
worker.worker1.type=ajp13
worker.worker1.host=172.20.23.12
worker.worker1.port=8009
worker.worker1.lbfactor=1
#worker.worker1.connection_pool_timeout=600
#worker.worker1.socket_keepalive=1
#worker.worker1.socket_timeout=60
worker.worker1.socket_timeout=0
# Define prefered failover node for worker1
worker.worker1.redirect=worker2

# Set properties for worker2 (ajp13)
worker.worker2.type=ajp13
worker.worker2.host=172.20.21.211
worker.worker2.port=8009
worker.worker2.lbfactor=1
#worker.worker2.connection_pool_timeout=600
#worker.worker2.socket_keepalive=1
#worker.worker2.socket_timeout=60
worker.worker2.socket_timeout=0
# Define prefered failover node for worker2
worker.worker2.redirect=worker1

method T (Traffic) does only make sense, if you are bandwidth limited in the network and thus want to balance w.r.t bytes transferred.

# Set properties for balancer which use worker1 and worker2
worker.cbnbalancer.type=lb
worker.cbnbalancer.method=T
worker.cbnbalancer.balance_workers=worker2,worker1
# Enable sticky-sessions (aka session affinity)
worker.cbnbalancer.sticky_session=1

# Define a 'jkstatus' worker using status
worker.jkstatus.type=status
# Add the jkstatus mount point

Maybe a little simpler, if you omit the trailing '*', thus mapping the exact URL /jkmanager/.

JkMount /jkmanager/* jkstatus
# Enable the JK manager access from localhost only
<!-- Location /jkmanager/>

You don't need the next line, because you already defined this mount.

 JkMount jkstatus
 Order deny,allow
 Deny from all
#  Allow from 127.0.0.1
 Allow from all
</Location -->

This is part of one server.xml

connectionTimeout=600000 would be a good fit to the 600 in your jk configuration.

2000 Threads is a lot, are you sure, that your OS can create that many Threads for a JVM (Memory issues possible)? If you only allow 700 parallel requests in Apache, you don't need more than 700 (+1?) threads in the AJP connector.

<Engine name="Catalina" defaultHost="localhost" jvmRoute="worker1" >

<Connector port="8009" minProcessors="5" maxThreads="2000" minSpareThreads="100" maxSpareThreads="150" maxProcessors="0"
protocol="AJP/1.3" connectionTimeout="0"/>

This is the second tomcat
<Engine name="Catalina" defaultHost="localhost" jvmRoute="worker2" >

<Connector port="8009" minProcessors="5" maxThreads="2000" minSpareThreads="100" maxSpareThreads="150" maxProcessors="0"
protocol="AJP/1.3" connectionTimeout="0"/>

This is part of the apache conf

Which mpm, prefork?

# number of server processes to start
       # http://httpd.apache.org/docs/2.2/mod/mpm_common.html#startservers
       StartServers         5
       # minimum number of server processes which are kept spare
       # http://httpd.apache.org/docs/2.2/mod/prefork.html#minspareservers
       MinSpareServers      5
       # maximum number of server processes which are kept spare
       # http://httpd.apache.org/docs/2.2/mod/prefork.html#maxspareservers
       MaxSpareServers     10
# highest possible MaxClients setting for the lifetime of the Apache process.
       # http://httpd.apache.org/docs/2.2/mod/mpm_common.html#serverlimit
       ServerLimit        700
       # maximum number of server processes allowed to start
       # http://httpd.apache.org/docs/2.2/mod/mpm_common.html#maxclients
       MaxClients         700
       # maximum number of requests a server process serves
# http://httpd.apache.org/docs/2.2/mod/mpm_common.html#maxrequestsperchild
       MaxRequestsPerChild  10000


We are trying to test this with 600 clients , when we reach 200 , everything gets stuck....

any ideas?

Thanks in advance four your help

JulioC.

How do clients relate to parallel requests?
What's the throughput before it gets stuck?
What does a Java Thread Dump of Tomcat tell you?
What is the status in the jk status worker?
Which kind of errors in the jk log do you get?

Regards,

Rainer


---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to