Tomcat connections...

Josh Miller joshua at itsecureadmin.com
Mon May 2 15:53:59 UTC 2011


On 04/29/2011 08:15 AM, Monty wig wrote:
> Gurus - I am working on a situation where Apache spits "Proxy Errors" while
> trying to get a page form Tomcat.
>
> We are running Apache 2.2.3 and tomcat 5.5 on the same box and using
> mod_proxy to redirect traffic to tomcat on port 8080. Tomcat has
> maxThreads=150 but when we look at the total # of connection on tomcat using
> "netstat" we get around 80 established connection, 140 connection in
> TIME_WAIT. So my question is does 150 maxThreads means total # of
> connections (ESTABLISHED + WAIT_TIME) or only ESTABLISHED connections...

Hi Monty,

I believe you've answered your own question there as 80 + 140 = 220.

You should have the capacity to have 150 connections in an ESTABLISHED 
state.

It seems to me that you need to take a thread dump of the java process 
and analyze that to see what tomcat is doing, if your logging is not 
telling you what is happening.  I would recommend getting familiar with 
jstack and using it often, ie:

sudo -u tomcat jstack -F <tomcat PID> > /tmp/outfile.jstack


HTH,
Josh Miller
Open Source Solutions Architect
http://itsecureadmin.com/



More information about the redhat-list mailing list