How to capture heap dumps of a JVM on a windows server

Last update: 2024-01-25
  • Created for:
  • Intermediate
    Admin

This video walks through the steps to capture heap dumps of a JVM on a windows server.

 Transcript

Hello everyone. In this video, we will be discussing the steps to capture heap dumps of a JVM on a Windows server. Heap dumps are vital artifacts to diagnose memory related problems such as slow memory leaks, garbage collection problems, and out of memory error.

To capture the heap dump, you need to follow some simple steps. Firstly, traverse to the JDK bin folder, and then type the jmap command with the heap dump file name, followed by the process ID of JVM, which we can obtain from the Task Manager.

By default, heap dump file is generated in the JDK bin folder itself.

To analyze the heap dump, we can simply launch “jvisualvm” under the JDK bin folder.

To load the heap dump file, traverse to the JDK bin folder and select the heap dump file we generated. By default, summary view opens up. We can also choose to look at the heap size percentage these classes are taking. We can also review the heap dump file using IBM heap dump analyzer tool. Thank you. -

On this page