Questions tagged [jmap]

A Hotspot JVM command-line utility that prints memory-related statistics for a running JVM or core file.

jmap is a command-line utility that serves as a tool for troubleshooting various memory-related issues in a Java Virtual Machine (JVM). jmap is distributed as a part of Oracle's Hotspot JVM, and so it can be used only for the Hotspot JVM.

jmap usually prints memory-related statistics for a running JVM or core file. Typical uses of jmap are :

  • jmap -histo <jvm-pid> - which prints class histogram of the instances present in the heap
  • jmap -heap <jvm-pid> - which prints a heap summary

A full list of command line options is available here.

163 questions
0
votes
1 answer

JMapper convert child Collection to Collection

I'm try to convert DemoEntity to DemoDto. And they have child attribute Collection and Collection. Error happened when converting Collection. If I don't add @JMap("subEntities"), JMapper would works well. Now I want…
H.Hao
  • 93
  • 2
  • 11
0
votes
2 answers

I want to insert a new Element at position 2 and Move other element One step Down ? is it possible

public class Data { public static void main(String[] args) { Map data = new LinkedHashMap(); data.put("1", "A"); data.put("2", "B"); data.put("3", "C"); data.put("4", "D"); } …
0
votes
0 answers

InvocationTargetException when converting a Windows minidump to hprof format

When trying to extract an hprof from a Windows minidump of a crashed JVM (-XX:+CreateMinidumpOnCrash) with jmap, I'm receiving an InvocationTargetException at about 31 MB of hprof file written (the mdmp file is 1700+ MB large): jmap…
Bass
  • 4,977
  • 2
  • 36
  • 82
0
votes
1 answer

Using JMAP on Sun WebServer 6.1 Instance

I have a webapp running on Sun One WebServer and I would like to use jmap to dump the heap space memory. When I list the processes running on my server, no java processes are listed, but only webservd processes (controlled by Sun WebServer). How do…
David
  • 177
  • 3
  • 5
0
votes
0 answers

how to get total and used heap memory of a process in java programatically

How to get total and used heap memory of a process in java? strong textint mb = 1024 * 1024; Runtime instance = Runtime.getRuntime(); System.out.println("***** Heap utilization statistics [MB] *****\n"); System.out.println("Total…
0
votes
0 answers

SOLARIS jmap error creating heapdump from core dump

I am getting the following error when attempting to create a heap dump from a core file generated through gcore on Solaris: jmap -J-d64 -dump:format=b,file=dump.hprof /usr/local/jdk/bin/java /tmp/core.15123 Attaching to core /tmp/core.15123 from…
Robert Rogers
  • 63
  • 1
  • 6
0
votes
3 answers

Can't dump heap on java process

I have a java process which I want to debug. The problem with it is that it has too many open connections, so running jmap fails because it can't connect to process. Running jmap -F produces the next error: Attaching to process ID 1772, please…
duduamar
  • 3,816
  • 7
  • 35
  • 54
0
votes
0 answers

jmap -dump:file=./dump.bin 8895

jmap -dump:file=./dump.bin 8895 I have used jmap to monitor the heap memory. I ran the about command. After that I opened the dump.bin. I could see some garbage. How can i check the heap memory consumed for an specific request. Thanks in advance.
0
votes
1 answer

Java jmap -heap command gave OutOfMemoryError

We are periodically runnign jmap -heap command to monitor a tomcat application. However this is first time when we got OutOfMemoryError. When we monitor the memory at server level there is around 110MB available. Since it is just monitoring can we…
Parvez
  • 631
  • 1
  • 6
  • 19
0
votes
1 answer

"can not get class data for sun/java2d/Disposer"

I have used a script successfully in the past and the JDK did not change, but for some reason in this instance I was unable to convert a core dump to a hprof; Attaching to core my.core from executable /opt/jdk1.8.0_31/bin/java, please…
user1133275
  • 2,642
  • 27
  • 31
0
votes
1 answer

What does the jvm option -XX:OnOutOfMemoryError=jmap do?

I am trying to monitor a process (which crashed due to Out Of Memory) last time on one production machine. The process is running with -XX:OnOutOfMemoryError=jmap option. What does it mean? Does it mean that it would produce a heap dump on…
kk1957
  • 8,246
  • 10
  • 41
  • 63
0
votes
2 answers

Printing jmap output for Heroku java application launched by a shell script

I want to log my Java application's jmap histogram periodically and this Heroku Dev page describes how to get jmap histos for a Heroku Java app by prefixing java command with with_jmap. However, what if I'm launching my Java app with a shell script…
Buchi
  • 1,322
  • 4
  • 14
  • 33
0
votes
0 answers

Thread dump and memory dump for JVM

I am trying to create Memory Dump and Thread Dump without using JDK tools like JMAP or JSTACK. I am not a java programmer, so not aware much about JDK. "PROJECT A" is developed using JAVA so JRE is a minimal requirement to RUN it. In JRE, tools like…
AMIT SHELKE
  • 501
  • 3
  • 12
  • 34
0
votes
0 answers

Process with 500 Mb resident memory generates a dump file of 250 Mb , memory analyzer tool just shows 7.5 Mb

I have some issues with memory, I have a process that increases its resident memory too much, I am trying to determinate whether there is a memory leak or not. Just opening the process, memory occupies 151 Mb VIRT RES SHR 792m 151m 14m After a…
bracana
  • 1,003
  • 2
  • 11
  • 20
0
votes
0 answers

No program line for ConcurrentodificationException

I need to use JMapViewer to display an image in to map but when I update the map I obtain Exception in thread "AWT-EventQueue-0" java.util.ConcurrentModificationException at java.util.LinkedList$ListItr.checkForComodification(Unknown Source) …
dofla
  • 3
  • 1
1 2 3
10
11