The moose likes Performance and the fly likes taking a heap dump Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Performance
Bookmark "taking a heap dump" Watch "taking a heap dump" New topic

taking a heap dump

gaurav abbi
Ranch Hand

Joined: Jan 05, 2007
Posts: 108
hi, can anybody suggest me a way to take heap dump, which can help me to analyze and debug memory leak.
i tried jmap, but that information is not very helpful for me.

thanks,<br />gaurav abbi
Henry Wong

Joined: Sep 28, 2004
Posts: 18553

Taking a heap dump, when you don't know what is leaking, is probably not the best course of action. It is probably better to use a profiler and monitor the heap as the application is leaking -- to see what grows.

Regardless, you still need to understand the application, in order to understand what should be growing and what shouldn't be growing.


Books: Java Threads, 3rd Edition, Jini in a Nutshell, and Java Gems (contributor)
rajesh bala
Ranch Hand

Joined: Jan 14, 2003
Posts: 66
Try latest JProfiler. It is very stable and good at detecting memory leaks.

If you can't afford, you can check their trial version. However I would highly recommend it, if you can buy it.

I have used it and extremely happy with its stability compared to JProbe. I am not advertising or working in JProfiler.

Fran├žois Mercier

Joined: Jan 12, 2007
Posts: 4
Try the excellent Memory Analyzer : http://www.eclipse.org/mat/
Consider Paul's rocket mass heater.
subject: taking a heap dump
Similar Threads
Analyse large heap dump file
JBoss 4.0.4 is slow down in every 20 days
Profiling using IBM Agent Controller with Rational SDP6.0
Jboss Out Of Memory Error on Linux
Connecting VisualVm with remote host