1jstack(1) Troubleshooting Tools jstack(1)
2
3
4
6 jstack - Prints Java thread stack traces for a Java process, core file,
7 or remote debug server. This command is experimental and unsupported.
8
10 jstack [ options ] pid
11
12 jstack [ options ] executable core
13
14 jstack [ options ] [ server-id@ ] remote-hostname-or-IP
15
16
17 options
18 The command-line options. See Options.
19
20 pid The process ID for which the stack trace is printed. The process
21 must be a Java process. To get a list of Java processes running
22 on a machine, use the jps(1) command.
23
24 executable
25 The Java executable from which the core dump was produced.
26
27 core The core file for which the stack trace is to be printed.
28
29 remote-hostname-or-IP
30 The remote debug server hostname or IP address. See
31 jsadebugd(1).
32
33 server-id
34 An optional unique ID to use when multiple debug servers are
35 running on the same remote host.
36
38 The jstack command prints Java stack traces of Java threads for a
39 specified Java process, core file, or remote debug server. For each
40 Java frame, the full class name, method name, byte code index (BCI),
41 and line number, when available, are printed. With the -m option, the
42 jstack command prints both Java and native frames of all threads with
43 the program counter (PC). For each native frame, the closest native
44 symbol to PC, when available, is printed. C++ mangled names are not
45 demangled. To demangle C++ names, the output of this command can be
46 piped to c++filt. When the specified process is running on a 64-bit
47 Java Virtual Machine, you might need to specify the -J-d64 option, for
48 example: jstack -J-d64 -m pid.
49
50 Note: This utility is unsupported and might not be available in future
51 release of the JDK. In Windows Systems where the dbgeng.dll file is not
52 present, Debugging Tools For Windows must be installed so these tools
53 work. The PATH environment variable needs to contain the location of
54 the jvm.dll that is used by the target process, or the location from
55 which the crash dump file was produced. For example:
56
57 set PATH=<jdk>\jre\bin\client;%PATH%
58
59
61 -F
62 Force a stack dump when jstack [-l] pid does not respond.
63
64 -l
65 Long listing. Prints additional information about locks such as
66 a list of owned java.util.concurrent ownable synchronizers. See
67 the AbstractOwnableSynchronizer class description at
68 http://docs.oracle.com/javase/8/docs/api/java/util/concurrent/locks/AbstractOwnableSynchronizer.html
69
70 -m
71 Prints a mixed mode stack trace that has both Java and native
72 C/C++ frames.
73
74 -h
75 Prints a help message.
76
77 -help
78 Prints a help message.
79
81 In mixed mode stack trace, the -m option does not work with the remote
82 debug server.
83
85 · pstack(1)
86
87 · C++filt(1)
88
89 · jps(1)
90
91 · jsadebugd(1)
92
93
94
95JDK 8 21 November 2013 jstack(1)