This problem had been plauging me for years, at random times Tomcat would just lock up and had to be restarted. My setup is similar to yours, four cocoon webapps running under tomcat 5.5 behind Apache. Dual PIII 933mhz with 1gig RAM on redhat 8
I FINALLY found the cause and solution: The problem was that, with four cocoon webapps, each having over 120 .jar files in WEB-INF/lib, and each with hundreds of .xsp pages, the JVM permanent generation was being filled up with more classes than it could handle. This would cause the JVM to thrash with constant garbage collection (and thus lock up Tomcat). I assumed that by increasing -Xmx I would be covered, but not so -- the permanent generation is a completely separate beast. Adding the following options to catalina.sh fixed the problem: -XX:PermSize=64M -XX:MaxPermSize=128M -XX:+CMSPermGenSweepingEnabled -XX:+CMSClassUnloadingEnabled Also, I found the JVM UseCMSInitiatingOccupancyOnly helped optimize the garbage collection even more. Here is the complete set of JVM options I use, they seem to be working great for the last month or so: -server -Xms256m -Xmx512m -Djava.awt.headless=true -XX:NewSize=24M -XX:MaxNewSize=24M -XX:PermSize=64M -XX:MaxPermSize=128M -XX:SurvivorRatio=128 -XX:MaxTenuringThreshold=0 -XX:+DisableExplicitGC -XX:+UseParNewGC -XX:ParallelGCThreads=2 -XX:+UseConcMarkSweepGC -XX:+CMSParallelRemarkEnabled -XX:+CMSPermGenSweepingEnabled -XX:+CMSClassUnloadingEnabled -XX:+UseCMSCompactAtFullCollection -XX:CMSFullGCsBeforeCompaction=0 -XX:CMSInitiatingOccupancyFraction=80 -XX:+UseCMSInitiatingOccupancyOnly A single CPU machine will need slightly different options. Hope this helps, +Ryan > >cocoon 2.0.4 and cocoon 2.1.6 > >on tomcat 5.0, redhat 9, with apache at front, serving > several cocoon > >based web sites > > > >the box: piv 2.4 1G Ram > > > > > >periodicaly tomcat hangs and needs restart > > > >i dont have figure until know what cause the problem > > > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
