Thursday, 15 November 2012

Generating Heap Dump In Linux/Jboss/Sun JVM

jmap -dump:live,file=<location to save the file>/<filename>.hprof <PID>

jmap -F -dump:live,file=/home/heapdump/heapdump.hprof 2323
 
For 64 bit JVM (should take default but some times if you have multiple JAVA in the same box), use below option:-                                                                                                                   

jmap -J-d64 -dump:live,file=<location to save the file>/<filename>.hprof <PID>



NOTE: you have to run "jmap" from your <JAVA_HOME/bin>

No comments:

Post a Comment