Getting "Unable to open socket file" message when executing jstack / jmap / jcmd and unable to generate a thread dump / heap dump
Issue
-
Got the following
"Unable to open socket file: target process not responding or HotSpot VM not loaded"when executingjstackcommand and unable to generate a thread dump:[root@myhost /tmp]# jstack -l <JAVA_PID> <JAVA_PID>: 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 -
Got the following
"Unable to open socket file: target process not responding or HotSpot VM not loaded"when executingjmapcommand and unable to generate a heap dump:[root@myhost /tmp]# jmap -dump:format=b,file=heap.hprof <JAVA_PID> <JAVA_PID>: 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 -
Same error was thrown when executing
jcmd <JAVA_PID> GC.heap_dump -all=true FILENAME.hprof - Got the above message when executing
jmap -histo:live <PID>command.
Environment
- Red Hat JBoss Enterprise Application Platform (EAP)
- JDK
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
