tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mladen Turk <mladen.t...@jboss.com>
Subject Re: mod_jk replacement?
Date Mon, 22 Jan 2007 18:15:55 GMT
JNeuhoff wrote:
> Is there another connector software available ...
> http://www.nabble.com/Apache-mod_jk-memory-leak--tf3023318.html

There are two major things why you can observe so called
'leak'.

When connecting Apache Httpd and Tomcat via mod_jk the major
thing you have to take into account is the fact that the
connection between those two is constant!

If any part closes this (AJP) connection you will observe
'memory leaak', meaning thread will stay open without the
clue the other part closed the connection.

For example thing like MaxRequestsPerChild will always
rise the number of threads in Tomcat causing 'Connection refuse'
error for mod_jk.

Next thing is difference between MaxClients (httpd) and
maxThreads(Tomcat). Once established the connection will
stay open for the server lifetime.

So the rule of the thumb is:
1. If there is MaxRequestsPerChild, add connectionTimeout
    to the AJP/1.3 connector in the server.xml

2. If there is an timeout in jk.conf, add connectionTimeout
    to the AJP/1.3 connector in the server.xml
    (60000 should be fine in most cases).


I've read all your posts to this thread and
Apache-mod_jk-memory-leak, and you didn't post the
server.xml config for AJP/1.3 connector, neither the
essential httpd.conf directives.

mod_jk works in production environments for many
users with multiple Apache Httpd servers in front
of multiple Tomcat/JBoss servers with thousands of
users per second without any memeory leak and running
for months. But like said you will first need to
understand the nature of connection between mod_jk and
Tomcat.

Regards,
Mladen.

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


Mime
View raw message