tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Rees <>
Subject Re: Tomcat Dies
Date Wed, 26 Nov 2003 01:17:13 GMT
Jeff Tulley wrote:
> What I have seen is that if there is a reasonably heavy load for a
> short amount of time, you can have too many sessions in memory that have
> not yet hit their session timeout value, and so cannot be freed by the
> garbage collector.  It is very easy to run out of memory well before
> sessions start being let go.  As far as I can tell though, once the
> sessions were freed, the memory itself cleared up.  (These comments
> apply to 4.1.28 BTW)

Jeff, have you tried a different session manager than the default (which 
is org.apache.catalina.session.StandardManager)?  For example, 
org.apache.catalina.session.PersistentManager claims to be able to start 
swapping out inactive sessions to disk to save memory.

A config like this inserted into your context should solve your memory 
issues with some performance hit if a session is swapped out to disk and 
is later swapped in.  However, the docs do warn that the manager hasn't 
been heavily tested.

<Manager className="org.apache.catalina.session.PersistentManager"
     <Store className="org.apache.catalina.session.FileStore"/>

The above config should swap out any sessions which haven't been 
accessed in the last 2 minutes.  You can also config a JDBC store.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message