In my endeavors to troubleshoot tomcat memory issues i performed the following in Ubuntu 10.04: sudo gedit /etc/init.d/tomcat6
Changed (~line 81): if [ -z "$JAVA_OPTS" ]; then JAVA_OPTS="-Djava.awt.headless=true -Xmx128M" fi
To: if [ -z "$JAVA_OPTS" ]; then JAVA_OPTS="-Djava.awt.headless=true -Xmx1024M -Xms1024M-XX:PermSize=256m -XX:MaxPermSize=256m -XX:NewSize=128m" fi
You can as well explicitly state in catalina.sh file as follows (in bold):
#!/bin/sh CATALINA_OPTS="-Xms1024m -Xmx1024m"
By, Jonah S. Mwogi