-
Bug
-
Resolution: Won't Fix
-
P4
-
None
-
11.0.18
-
x86_64
-
linux_ubuntu
ADDITIONAL SYSTEM INFORMATION :
Ubuntu 22.04 on x86_64; Ubuntu package 11.0.18+10-0ubuntu1~22.04
A DESCRIPTION OF THE PROBLEM :
I have a core file from a JVM instance that crashed with SIGABRT due an assert in JNI code.
I am trying to create a heap dump from it from "jhsdb jmap", but it fails with
Exception in thread "main" java.lang.IndexOutOfBoundsException: bad SID 0
Note: this issue was also reported asJDK-8237544 but that issue was closed as Incomplete for lack of feedback from the submitter; I can provide more information if needed.
Without the --binaryheap option, the tool is able to successfully output the high-level map data from the crash.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Extract a specific core file from an Ubuntu /var/crash file using apport-unpack
Execute
$ jhsdb jmap --exe $(<ExecutablePath) --core CoreDump --binaryheap
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
Attaching to core CoreDump from executable /usr/lib/jvm/java-11-openjdk-amd64/bin/java, please wait...
Debugger attached successfully.
Server compiler detected.
JVM version is 11.0.18+10-post-Ubuntu-0ubuntu122.04
heap written to heap.bin
ACTUAL -
Attaching to core CoreDump from executable /usr/lib/jvm/java-11-openjdk-amd64/bin/java, please wait...
Debugger attached successfully.
Server compiler detected.
JVM version is 11.0.18+10-post-Ubuntu-0ubuntu122.04
Exception in thread "main" java.lang.IndexOutOfBoundsException: bad SID 0
at jdk.hotspot.agent/sun.jvm.hotspot.runtime.vmSymbols.symbolAt(vmSymbols.java:58)
at jdk.hotspot.agent/sun.jvm.hotspot.oops.InstanceKlass.getFieldName(InstanceKlass.java:353)
at jdk.hotspot.agent/sun.jvm.hotspot.oops.InstanceKlass.<init>(InstanceKlass.java:153)
at jdk.internal.reflect.GeneratedConstructorAccessor1.newInstance(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490)
at jdk.hotspot.agent/sun.jvm.hotspot.runtime.VMObjectFactory.newObject(VMObjectFactory.java:58)
at jdk.hotspot.agent/sun.jvm.hotspot.runtime.VirtualBaseConstructor.instantiateWrapperFor(VirtualBaseConstructor.java:104)
at jdk.hotspot.agent/sun.jvm.hotspot.oops.Metadata.instantiateWrapperFor(Metadata.java:73)
at jdk.hotspot.agent/sun.jvm.hotspot.oops.java_lang_Class.asKlass(java_lang_Class.java:67)
at jdk.hotspot.agent/sun.jvm.hotspot.utilities.HeapHprofBinWriter.writeClass(HeapHprofBinWriter.java:611)
at jdk.hotspot.agent/sun.jvm.hotspot.utilities.AbstractHeapGraphWriter$1.doObj(AbstractHeapGraphWriter.java:82)
at jdk.hotspot.agent/sun.jvm.hotspot.oops.ObjectHeap.iterateLiveRegions(ObjectHeap.java:356)
at jdk.hotspot.agent/sun.jvm.hotspot.oops.ObjectHeap.iterate(ObjectHeap.java:174)
at jdk.hotspot.agent/sun.jvm.hotspot.utilities.AbstractHeapGraphWriter.write(AbstractHeapGraphWriter.java:51)
at jdk.hotspot.agent/sun.jvm.hotspot.utilities.HeapHprofBinWriter.write(HeapHprofBinWriter.java:443)
at jdk.hotspot.agent/sun.jvm.hotspot.tools.JMap.writeHeapHprofBin(JMap.java:182)
at jdk.hotspot.agent/sun.jvm.hotspot.tools.JMap.run(JMap.java:97)
at jdk.hotspot.agent/sun.jvm.hotspot.tools.Tool.startInternal(Tool.java:260)
at jdk.hotspot.agent/sun.jvm.hotspot.tools.Tool.start(Tool.java:223)
at jdk.hotspot.agent/sun.jvm.hotspot.tools.Tool.execute(Tool.java:118)
at jdk.hotspot.agent/sun.jvm.hotspot.tools.JMap.main(JMap.java:176)
at jdk.hotspot.agent/sun.jvm.hotspot.SALauncher.runJMAP(SALauncher.java:369)
at jdk.hotspot.agent/sun.jvm.hotspot.SALauncher.main(SALauncher.java:538)
FREQUENCY : occasionally
Ubuntu 22.04 on x86_64; Ubuntu package 11.0.18+10-0ubuntu1~22.04
A DESCRIPTION OF THE PROBLEM :
I have a core file from a JVM instance that crashed with SIGABRT due an assert in JNI code.
I am trying to create a heap dump from it from "jhsdb jmap", but it fails with
Exception in thread "main" java.lang.IndexOutOfBoundsException: bad SID 0
Note: this issue was also reported as
Without the --binaryheap option, the tool is able to successfully output the high-level map data from the crash.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Extract a specific core file from an Ubuntu /var/crash file using apport-unpack
Execute
$ jhsdb jmap --exe $(<ExecutablePath) --core CoreDump --binaryheap
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
Attaching to core CoreDump from executable /usr/lib/jvm/java-11-openjdk-amd64/bin/java, please wait...
Debugger attached successfully.
Server compiler detected.
JVM version is 11.0.18+10-post-Ubuntu-0ubuntu122.04
heap written to heap.bin
ACTUAL -
Attaching to core CoreDump from executable /usr/lib/jvm/java-11-openjdk-amd64/bin/java, please wait...
Debugger attached successfully.
Server compiler detected.
JVM version is 11.0.18+10-post-Ubuntu-0ubuntu122.04
Exception in thread "main" java.lang.IndexOutOfBoundsException: bad SID 0
at jdk.hotspot.agent/sun.jvm.hotspot.runtime.vmSymbols.symbolAt(vmSymbols.java:58)
at jdk.hotspot.agent/sun.jvm.hotspot.oops.InstanceKlass.getFieldName(InstanceKlass.java:353)
at jdk.hotspot.agent/sun.jvm.hotspot.oops.InstanceKlass.<init>(InstanceKlass.java:153)
at jdk.internal.reflect.GeneratedConstructorAccessor1.newInstance(Unknown Source)
at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:490)
at jdk.hotspot.agent/sun.jvm.hotspot.runtime.VMObjectFactory.newObject(VMObjectFactory.java:58)
at jdk.hotspot.agent/sun.jvm.hotspot.runtime.VirtualBaseConstructor.instantiateWrapperFor(VirtualBaseConstructor.java:104)
at jdk.hotspot.agent/sun.jvm.hotspot.oops.Metadata.instantiateWrapperFor(Metadata.java:73)
at jdk.hotspot.agent/sun.jvm.hotspot.oops.java_lang_Class.asKlass(java_lang_Class.java:67)
at jdk.hotspot.agent/sun.jvm.hotspot.utilities.HeapHprofBinWriter.writeClass(HeapHprofBinWriter.java:611)
at jdk.hotspot.agent/sun.jvm.hotspot.utilities.AbstractHeapGraphWriter$1.doObj(AbstractHeapGraphWriter.java:82)
at jdk.hotspot.agent/sun.jvm.hotspot.oops.ObjectHeap.iterateLiveRegions(ObjectHeap.java:356)
at jdk.hotspot.agent/sun.jvm.hotspot.oops.ObjectHeap.iterate(ObjectHeap.java:174)
at jdk.hotspot.agent/sun.jvm.hotspot.utilities.AbstractHeapGraphWriter.write(AbstractHeapGraphWriter.java:51)
at jdk.hotspot.agent/sun.jvm.hotspot.utilities.HeapHprofBinWriter.write(HeapHprofBinWriter.java:443)
at jdk.hotspot.agent/sun.jvm.hotspot.tools.JMap.writeHeapHprofBin(JMap.java:182)
at jdk.hotspot.agent/sun.jvm.hotspot.tools.JMap.run(JMap.java:97)
at jdk.hotspot.agent/sun.jvm.hotspot.tools.Tool.startInternal(Tool.java:260)
at jdk.hotspot.agent/sun.jvm.hotspot.tools.Tool.start(Tool.java:223)
at jdk.hotspot.agent/sun.jvm.hotspot.tools.Tool.execute(Tool.java:118)
at jdk.hotspot.agent/sun.jvm.hotspot.tools.JMap.main(JMap.java:176)
at jdk.hotspot.agent/sun.jvm.hotspot.SALauncher.runJMAP(SALauncher.java:369)
at jdk.hotspot.agent/sun.jvm.hotspot.SALauncher.main(SALauncher.java:538)
FREQUENCY : occasionally
- relates to
-
JDK-8237544 Failed to create heap dump file with "jhsdb jmap"
-
- Closed
-