sun.jvm.hotspot.runtime.VMVersionMismatchException: Supported versions are 24.79-b02. Target VM is 2

[weblogic@sys03 logs]$ jmap -heap 25782
Attaching to process ID 25782, please wait...
Warning: the type "const char*" (declared in the remote VM in VMStructs::localHotSpotVMTypes) had its size declared as 8 twice. Continuing.
Warning: the type "const size_t" (declared in the remote VM in VMStructs::localHotSpotVMTypes) had its size declared as 8 twice. Continuing.
Warning: the type "const int" (declared in the remote VM in VMStructs::localHotSpotVMTypes) had its size declared as 4 twice. Continuing.
Warning: the type "const MemRegion" (declared in the remote VM in VMStructs::localHotSpotVMTypes) had its size declared as 16 twice. Continuing.
Exception in thread "main" java.lang.reflect.InvocationTargetException
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:606)
        at sun.tools.jmap.JMap.runTool(JMap.java:197)
        at sun.tools.jmap.JMap.main(JMap.java:128)
Caused by: sun.jvm.hotspot.runtime.VMVersionMismatchException: Supported versions are 24.79-b02. Target VM is 20.14-b01
        at sun.jvm.hotspot.runtime.VM.checkVMVersion(VM.java:234)
        at sun.jvm.hotspot.runtime.VM.(VM.java:297)
        at sun.jvm.hotspot.runtime.VM.initialize(VM.java:368)
        at sun.jvm.hotspot.bugspot.BugSpotAgent.setupVM(BugSpotAgent.java:598)
        at sun.jvm.hotspot.bugspot.BugSpotAgent.go(BugSpotAgent.java:493)
        at sun.jvm.hotspot.bugspot.BugSpotAgent.attach(BugSpotAgent.java:331)
        at sun.jvm.hotspot.tools.Tool.start(Tool.java:163)
        at sun.jvm.hotspot.tools.HeapSummary.main(HeapSummary.java:40)
        ... 6 more

上面报错原因的安装了多个版本的jdk ,使用是需要具体指定使用哪个jdk

eg:  /usr/java/jdk1.6.0_45/bin/jmap -heap 3333

你可能感兴趣的:(故障处理,java)