Hi guys,

 I have a nagging problem. I am running Tomcat 3.3 with Apache 1.3 on Redhat
7.2, kernel 2.4.17, Sun's Java 1.3.1
 The problem I am having is that sometimes Tomcat refuses to spawn new java
thread. If I look at the processes there would be exactly 218 java
processes/threads running. Looks like this is the maximum number of
processes Tomcat and/or java can spawn. Restarting Tomcat helps - until next
time.
 I suspect that some .jsp and/or servlets do not properly quit/close/free
resources and Tomcat still thinks they are running and cannot clear those
threads up. 
 Workaround, I thought, would be to bump up maximum number of Tomcat
threads. I do restart Tomcat every night after logrotate, so I thought if I
set maxThreads to something bigger than default (200, according to Tomcat
docs), it would be enough to keep me running. 
 Here is a snippet from my server.xml:

 <Ajp12Connector  port="8007"
                 ajpidFile="/usr/local/tomcat/conf/ajp12.id"
                 address="127.0.0.1"
                 maxThreads="1"
                 tomcatAuthentication="false" />
<Ajp13Connector port="8009"
                address="127.0.0.1"
                maxSpareThreads="10"
                maxThreads="400"
                tomcatAuthentication="false" />

 Setting maxThreads for Ajp13 connector to 400 did not change anything.
Still, every once in a while I will have 218 java threads an Tomcat will
stop taking new connections.

 I have a couple of questions regarding this stuff:
1. How do I increase the number of Tomcat threads? Where does number 218
come from?
2. Is there any way to tell what each java thread running? This way I could
tell programmers what ties Tomcat up so they can fix the code - I am not
much of a programmer :-(.

 Am I looking in the correct direction at all? Could it be something
completely different?

Reply via email to