Questions tagged [heap-dump]

A heap dump is a snapshot of the memory of a Java process.

A heap dump is a snapshot of the memory of a Java process.

The snapshot contains information about the Java objects and classes in the heap at the moment the snapshot is triggered. Because there are different formats for persisting this data, there might be some differences in the information provided. Typically, a full garbage collection is triggered before the heap dump is written, so the dump contains information about the remaining objects in the heap.

All Objects: Class, fields, primitive values, and references.

All Classes: Class loader, name, super class, and static fields.

Garbage collection roots: Objects defined to be reachable by the JVM.

Thread Stacks and Local Variables: Call-stacks of threads at the moment of the snapshot, and information about local objects on a frame by frame basis.

A heap dump does not contain allocation information, therefore you cannot work out what created the objects or where the objects were created.

Source

485 questions
6
votes
2 answers

Can JVisualVM "Heap Dump" button release memory?

i have a very strange problem. I'm working on an OSGi application, based on Eclipse Equinox; it was developed using OSGi Log Service (Equinox implementation) and now I'm testing it with the Apache Felix OSGi Log Service implementation. At API/code…
elDarioz
  • 61
  • 1
  • 2
6
votes
1 answer

Meaning of icons in HPROF Viewer in Android Studio

From time to time I use the Memory Monitor and HPROF Viewer in Android Studio to check for any memory leaks and memory usage in general. I believe I know the meaning of most symbols and colours used in the Viewer, but I would like to be sure and not…
Roy Solberg
  • 18,133
  • 12
  • 49
  • 76
6
votes
0 answers

YARN parameter to take heap dump before killing container

I have a long-running yarn application (not m/r) with containers that occasionally exceed the yarn memory limit, at which point yarn kills the offending containers. I am finding it difficult to determine what is causing the heap growth. Is there a…
MicGer
  • 305
  • 4
  • 8
6
votes
1 answer

Installing DTJF on Eclipse Memory Analyzer to read .phd files

I have Eclipse Memory Analyzer v1.3.1, and need to analyze some .phd heap dumps. According to this question, it is necessary to install DTJF on Eclipse Memory Analyzer. This link in the question says: Memory Analyzer can also read memory-related…
Andy
  • 2,770
  • 9
  • 35
  • 42
6
votes
2 answers

How to take heap snapshot of Xamarin.Android's Mono VM?

Background: I am trying to track down a memory leak in a Xamarin.Android app. Using DDMS and Eclipse Memory Profiler, I am able to see which objects are alive. When trying to track what is holding them alive (GC Root), I only see "Native stack" (of…
Paul Kapustin
  • 3,297
  • 5
  • 35
  • 45
6
votes
1 answer

Generating Heap Dumps Java JRE7

I'm trying to generate a heap dump from my java program, but no matter what I seem to try I can't seem to figure out how to do so. I downloaded the Eclipse Memory Analyzer (Plugin and then Standalone) which is supposed to be able to aquire heat…
user2491165
  • 63
  • 1
  • 3
6
votes
2 answers

Programmatically analyze java heap dump file

I want to write a program (preferably in java) that will parse and analyze a java heap dump file (created by jmap). I know there are many great tools that already do so (jhat, eclipse's MAT, and so on), but I want to analyze the heap from a specific…
duduamar
  • 3,816
  • 7
  • 35
  • 54
5
votes
2 answers

Persist heap dump in case of OOM in kubernetes pod?

I need to persist the heap dump when the java process gets OOM and the pod is restarted. I have following added in the jvm args -XX:+ExitOnOutOfMemoryError -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/opt/dumps ...and emptydir is mounted on…
5
votes
1 answer

Create JVM heapdump when K8s healthcheck restarts the pod - no OOM occur

I have a situation when all of a sudden a really long GC pause occurs and I need to find out what is the source of the sudden memory allocation. The long GC pause (around 30 seconds) causes the pod to fail several K8s health checks in a row and the…
Kikosha
  • 343
  • 6
  • 16
5
votes
3 answers

How to analyze a large heapdump?

Is there a tool to analyze a large Java Heap dump (2GB), if one only can assign 1,5GB to the JVM? I can't believe the dump must be fully loaded into memory to be analyzed... Eclipse MemoryAnalyzer fails, and the IBM tool also. Do I need to use…
Daniel
  • 27,718
  • 20
  • 89
  • 133
5
votes
0 answers

Error: Cannot find module './build/Debug/addon' after deploying to docker container

I am using below versions. node -v v8.16.0 heapdump : 0.3.12 The below error is getting once I deploy the code to docker container. The local setup is working fine without this issue. Error: Cannot find module './build/Debug/addon' Kindly help on…
vijaychow7
  • 61
  • 3
5
votes
1 answer

Are heap snapshot identifiers guaranteed to be monotonically increasing?

I'm using heap snapshots to debug a potential memory issue. As the documentation indicates objects are shown in this format: ObjectConstructorName@NumericIdentifier Where NumericIdentifier is: This is an object ID. Displaying an object's address…
Benjamin Gruenbaum
  • 270,886
  • 87
  • 504
  • 504
5
votes
2 answers

Write JVM heap dump to stdout

We are using the following JVM flags to run a Spring Boot app inside Docker (managed by Kubernetes) -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/tmp -XX:+ExitOnOutofMemoryError As expected, the container gets restarted upon an OOM exception.…
Ananth
  • 307
  • 3
  • 14
5
votes
2 answers

How to analyse Dalvik GC behaviour?

I am developing an application on Android. It is a long running application that continuously processes sensor data. While running the application I see a lot of GC messages in the logcat; about one every second. This is most probably because of…
HRJ
  • 17,079
  • 11
  • 56
  • 80
5
votes
2 answers

Best method for inspecting Elastic Beanstalk JVM heap

I'm need to get a JVM heap dump from an Elastic Beanstalk server, but the server doesn't have jcmd or jmap. Amazon doesn't natively install them with the JDK. Here's what's installed: [ec2-user@ip-x-x-x-x ~]$ sudo yum list installed|grep…
Thomas Kessler
  • 1,717
  • 3
  • 16
  • 27