Tomcat

check tomcat version
/opt/tomcat/bin/version.sh

tomcat6 cluster

 * https://tomcat.apache.org/tomcat-6.0-doc/cluster-howto.html

tomcat 7 outofmemeory heap dump

 * https://newfivefour.com/tomcat7-heap-dump-out-of-memory.html

JAVA_OPTS='-XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/path/to/dir'
 * in catalina.sh

long[] l = new long[Integer.MAX_VALUE];
 * one line java code cause out of memory


 * java heap annlize - http://www.eclipse.org/mat/