2014-09-22 5 views
1

응용 프로그램이 작동하지 않는 경우 스레드 상태를 확인하고 싶습니다. 하지만 내 Java 응용 프로그램에 대해 jstack -l을 실행할 수 없습니다.

Unable to open socket file: target process not responding or HotSpot VM not loaded 
The -F option can be used when the target process is not responding 

은 그럼 쓰레드 덤프을 시도하는 -F를 사용 ... 내 응용 프로그램에서 jstack을 -l 33822를 통해 스레드 덤프를 취할 수 없었다. 다음과 같은 오류가 발생했습니다.

Attaching to process ID 33822, please wait... 
    Debugger attached successfully. 
    Server compiler detected. 
    JVM version is 23.21-b01 
    Deadlock Detection: 
    sun.jvm.hotspot.debugger.UnmappedAddressException: 3780320 
      at sun.jvm.hotspot.debugger.PageCache.checkPage(PageCache.java:208) 
      at sun.jvm.hotspot.debugger.PageCache.getData(PageCache.java:63) 
      at sun.jvm.hotspot.debugger.DebuggerBase.readBytes(DebuggerBase.java:217) 
      at sun.jvm.hotspot.debugger.linux.LinuxDebuggerLocal.readCInteger(LinuxDebuggerLocal.java:482) 
      at sun.jvm.hotspot.debugger.DebuggerBase.readCompOopAddressValue(DebuggerBase.java:459) 
      at sun.jvm.hotspot.debugger.linux.LinuxDebuggerLocal.readCompOopHandle(LinuxDebuggerLocal.java:442) 
      at sun.jvm.hotspot.debugger.linux.LinuxAddress.getCompOopHandleAt(LinuxAddress.java:125) 
      at sun.jvm.hotspot.oops.Oop.getKlassForOopHandle(Oop.java:231) 
      at sun.jvm.hotspot.oops.ObjectHeap.newOop(ObjectHeap.java:380) 
      at sun.jvm.hotspot.runtime.JavaThread.getThreadObj(JavaThread.java:331) 
      at sun.jvm.hotspot.runtime.JavaThread.getCurrentParkBlocker(JavaThread.java:383) 
      at sun.jvm.hotspot.runtime.DeadlockDetector.print(DeadlockDetector.java:82) 
      at sun.jvm.hotspot.runtime.DeadlockDetector.print(DeadlockDetector.java:39) 
      at sun.jvm.hotspot.tools.StackTrace.run(StackTrace.java:52) 
      at sun.jvm.hotspot.tools.StackTrace.run(StackTrace.java:45) 
      at sun.jvm.hotspot.tools.JStack.run(JStack.java:60) 
      at sun.jvm.hotspot.tools.Tool.start(Tool.java:221) 
      at sun.jvm.hotspot.tools.JStack.main(JStack.java:86) 
      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:601) 
      at sun.tools.jstack.JStack.runJStackTool(JStack.java:136) 
      at sun.tools.jstack.JStack.main(JStack.java:102) 
    sun.jvm.hotspot.debugger.UnmappedAddressException: 10 
      at sun.jvm.hotspot.debugger.PageCache.checkPage(PageCache.java:208) 
      at sun.jvm.hotspot.debugger.PageCache.getData(PageCache.java:63) 
      at sun.jvm.hotspot.debugger.DebuggerBase.readBytes(DebuggerBase.java:217) 
      at sun.jvm.hotspot.debugger.linux.LinuxDebuggerLocal.readCInteger(LinuxDebuggerLocal.java:482) 
      at sun.jvm.hotspot.debugger.DebuggerBase.readCompOopAddressValue(DebuggerBase.java:459) 
      at sun.jvm.hotspot.debugger.linux.LinuxDebuggerLocal.readCompOopHandle(LinuxDebuggerLocal.java:442) 
      at sun.jvm.hotspot.debugger.linux.LinuxAddress.getCompOopHandleAt(LinuxAddress.java:125) 
      at sun.jvm.hotspot.oops.Oop.getKlassForOopHandle(Oop.java:231) 
      at sun.jvm.hotspot.oops.ObjectHeap.newOop(ObjectHeap.java:356) 
      at sun.jvm.hotspot.oops.NarrowOopField.getValue(NarrowOopField.java:44) 
      at sun.jvm.hotspot.oops.OopUtilities.threadOopGetParkBlocker(OopUtilities.java:294) 
      at sun.jvm.hotspot.runtime.JavaThread.getCurrentParkBlocker(JavaThread.java:385) 
      at sun.jvm.hotspot.runtime.DeadlockDetector.print(DeadlockDetector.java:82) 
      at sun.jvm.hotspot.runtime.DeadlockDetector.print(DeadlockDetector.java:39) 
      at sun.jvm.hotspot.tools.StackTrace.run(StackTrace.java:52) 
      at sun.jvm.hotspot.tools.StackTrace.run(StackTrace.java:45) 
      at sun.jvm.hotspot.tools.JStack.run(JStack.java:60) 
      at sun.jvm.hotspot.tools.Tool.start(Tool.java:221) 
      at sun.jvm.hotspot.tools.JStack.main(JStack.java:86) 
      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:601) 
      at sun.tools.jstack.JStack.runJStackTool(JStack.java:136) 
      at sun.tools.jstack.JStack.main(JStack.java:102) 
    Can't print deadlocks:10 

JVM의 defect입니까?

답변

1

어쨌든 threaddump가 실행되지 않았습니까? 이 오류가 발생하지만 작은 대기 후에도 여전히 스레드 덤프가 발생합니다.