rjshuttleworth
24-09-2010, 07:53
Anyone experienced an issue attaching to a VM to do a heap dump? I am getting an incorrect version reported. Here's a jmap output:
[root@domU-12-31-39-0E-AE-12 ~]# jmap 27624
Attaching to process ID 27624, please wait...
Exception in thread "main" java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Nativ e Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Native MethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(De legatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616)
at sun.tools.jmap.JMap.runTool(JMap.java:196)
at sun.tools.jmap.JMap.main(JMap.java:128)
Caused by: sun.jvm.hotspot.runtime.VMVersionMismatchException : Supported versions are 1.6.0-b09. Target VM is 10.0-b19
at sun.jvm.hotspot.runtime.VM.checkVMVersion(VM.java: 217)
at sun.jvm.hotspot.runtime.VM.<init>(VM.java:280)
at sun.jvm.hotspot.runtime.VM.initialize(VM.java:333)
at sun.jvm.hotspot.bugspot.BugSpotAgent.setupVM(BugSp otAgent.java:594)
at sun.jvm.hotspot.bugspot.BugSpotAgent.go(BugSpotAge nt.java:494)
at sun.jvm.hotspot.bugspot.BugSpotAgent.attach(BugSpo tAgent.java:332)
at sun.jvm.hotspot.tools.Tool.start(Tool.java:163)
at sun.jvm.hotspot.tools.HeapSummary.main(HeapSummary .java:39)
... 6 more
and here's my java version:
[root@domU-12-31-39-0E-AE-12 ~]# java -version
java version "1.6.0_04"
Java(TM) SE Runtime Environment (build 1.6.0_04-b12)
Java HotSpot(TM) 64-Bit Server VM (build 10.0-b19, mixed mode)
[root@domU-12-31-39-0E-AE-12 ~]#
Seems to me that running in server mode reports back to jmap the wrong version number.
I am running jmap from the bin directory of the VM that is running my service (tcserver) and it's definitely java 1.6!
Any ideas?
Ryan
[root@domU-12-31-39-0E-AE-12 ~]# jmap 27624
Attaching to process ID 27624, please wait...
Exception in thread "main" java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Nativ e Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Native MethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(De legatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:616)
at sun.tools.jmap.JMap.runTool(JMap.java:196)
at sun.tools.jmap.JMap.main(JMap.java:128)
Caused by: sun.jvm.hotspot.runtime.VMVersionMismatchException : Supported versions are 1.6.0-b09. Target VM is 10.0-b19
at sun.jvm.hotspot.runtime.VM.checkVMVersion(VM.java: 217)
at sun.jvm.hotspot.runtime.VM.<init>(VM.java:280)
at sun.jvm.hotspot.runtime.VM.initialize(VM.java:333)
at sun.jvm.hotspot.bugspot.BugSpotAgent.setupVM(BugSp otAgent.java:594)
at sun.jvm.hotspot.bugspot.BugSpotAgent.go(BugSpotAge nt.java:494)
at sun.jvm.hotspot.bugspot.BugSpotAgent.attach(BugSpo tAgent.java:332)
at sun.jvm.hotspot.tools.Tool.start(Tool.java:163)
at sun.jvm.hotspot.tools.HeapSummary.main(HeapSummary .java:39)
... 6 more
and here's my java version:
[root@domU-12-31-39-0E-AE-12 ~]# java -version
java version "1.6.0_04"
Java(TM) SE Runtime Environment (build 1.6.0_04-b12)
Java HotSpot(TM) 64-Bit Server VM (build 10.0-b19, mixed mode)
[root@domU-12-31-39-0E-AE-12 ~]#
Seems to me that running in server mode reports back to jmap the wrong version number.
I am running jmap from the bin directory of the VM that is running my service (tcserver) and it's definitely java 1.6!
Any ideas?
Ryan