Take the 2-minute tour ×  I have an application that keeps
throwing OOM exceptions, however when I review the heap dumps
there is always some amount of unused heap space. Does anyone
have an idea why this might happen? I was thinking that maybe an
object was getting created that cause the OOM but wouldn't that
show up in the heap dump?  EDIT settings:
/usr/local/jre/bin/java -Xmx2048M -Xms2048M -server
-XX:MaxPermSize=128M -Djava.util.logging.manager=org.apache.juli
.ClassLoaderLogManager -Djava.util.logging.config.file=/usr/loca
l/tomcat/conf/logging.properties -Dcom.sun.management.jmxremote
-Dcom.sun.management.jmxremote.port=8998
-Dcom.sun.management.jmxremote.ssl=false
-Dcom.sun.management.jmxremote.authenticate=false
-Djava.endorsed.dirs=/usr/local/tomcat/common/endorsed
-classpath :/usr/local/tomcat/bin/bootstrap.jar:/usr/local/tomca
t/bin/commons-logging-api.jar -Dcatalina.base=/usr/local/tomcat
-Dcatalina.home=/usr/local/tomcat
-Djava.io.tmpdir=/usr/local/tomcat/temp
org.apache.catalina.startup.Bootstrap