jdk/src/linux/doc/man/jstack.1
author katleman
Fri, 20 Jan 2012 13:08:48 -0800
changeset 11494 0720b6b09943
parent 9573 c02ff5a7c67b
child 21743 3d979da7bdf0
permissions -rw-r--r--
Added tag jdk8-b22 for changeset 054ae6fb4346
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
9573
c02ff5a7c67b 7043684: Update man pages for JDK 7 tools
bpatel
parents: 5865
diff changeset
     1
." Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
     2
." DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
90ce3da70b43 Initial load
duke
parents:
diff changeset
     3
."
90ce3da70b43 Initial load
duke
parents:
diff changeset
     4
." This code is free software; you can redistribute it and/or modify it
90ce3da70b43 Initial load
duke
parents:
diff changeset
     5
." under the terms of the GNU General Public License version 2 only, as
90ce3da70b43 Initial load
duke
parents:
diff changeset
     6
." published by the Free Software Foundation.
90ce3da70b43 Initial load
duke
parents:
diff changeset
     7
."
90ce3da70b43 Initial load
duke
parents:
diff changeset
     8
." This code is distributed in the hope that it will be useful, but WITHOUT
90ce3da70b43 Initial load
duke
parents:
diff changeset
     9
." ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
90ce3da70b43 Initial load
duke
parents:
diff changeset
    10
." FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
90ce3da70b43 Initial load
duke
parents:
diff changeset
    11
." version 2 for more details (a copy is included in the LICENSE file that
90ce3da70b43 Initial load
duke
parents:
diff changeset
    12
." accompanied this code).
90ce3da70b43 Initial load
duke
parents:
diff changeset
    13
."
90ce3da70b43 Initial load
duke
parents:
diff changeset
    14
." You should have received a copy of the GNU General Public License version
90ce3da70b43 Initial load
duke
parents:
diff changeset
    15
." 2 along with this work; if not, write to the Free Software Foundation,
90ce3da70b43 Initial load
duke
parents:
diff changeset
    16
." Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    17
."
5506
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2692
diff changeset
    18
." Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2692
diff changeset
    19
." or visit www.oracle.com if you need additional information or have any
202f599c92aa 6943119: Rebrand source copyright notices
ohair
parents: 2692
diff changeset
    20
." questions.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    21
."
9573
c02ff5a7c67b 7043684: Update man pages for JDK 7 tools
bpatel
parents: 5865
diff changeset
    22
.TH jstack 1 "10 May 2011"
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    23
90ce3da70b43 Initial load
duke
parents:
diff changeset
    24
.LP
2692
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
    25
.SH "Name"
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    26
jstack \- Stack Trace
90ce3da70b43 Initial load
duke
parents:
diff changeset
    27
.br
90ce3da70b43 Initial load
duke
parents:
diff changeset
    28
90ce3da70b43 Initial load
duke
parents:
diff changeset
    29
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    30
.SH "SYNOPSIS"
90ce3da70b43 Initial load
duke
parents:
diff changeset
    31
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    32
.nf
90ce3da70b43 Initial load
duke
parents:
diff changeset
    33
\f3
90ce3da70b43 Initial load
duke
parents:
diff changeset
    34
.fl
90ce3da70b43 Initial load
duke
parents:
diff changeset
    35
\fP\f3jstack\fP [ option ] pid
90ce3da70b43 Initial load
duke
parents:
diff changeset
    36
.fl
90ce3da70b43 Initial load
duke
parents:
diff changeset
    37
\f3jstack\fP [ option ] executable core
90ce3da70b43 Initial load
duke
parents:
diff changeset
    38
.fl
90ce3da70b43 Initial load
duke
parents:
diff changeset
    39
\f3jstack\fP [ option ] [server\-id@]remote\-hostname\-or\-IP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    40
.fl
90ce3da70b43 Initial load
duke
parents:
diff changeset
    41
.fi
90ce3da70b43 Initial load
duke
parents:
diff changeset
    42
90ce3da70b43 Initial load
duke
parents:
diff changeset
    43
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    44
.SH "PARAMETERS"
90ce3da70b43 Initial load
duke
parents:
diff changeset
    45
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    46
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    47
Options are mutually exclusive. Option, if used, should follow immediately after the command name. See OPTIONS.
90ce3da70b43 Initial load
duke
parents:
diff changeset
    48
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    49
.RS 3
90ce3da70b43 Initial load
duke
parents:
diff changeset
    50
.TP 3
90ce3da70b43 Initial load
duke
parents:
diff changeset
    51
pid 
2692
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
    52
process id for which the stack trace is to be printed. The process must be a Java process. To get a list of Java processes running on a machine, jps(1) may be used. 
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    53
.RE
90ce3da70b43 Initial load
duke
parents:
diff changeset
    54
90ce3da70b43 Initial load
duke
parents:
diff changeset
    55
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    56
.RS 3
90ce3da70b43 Initial load
duke
parents:
diff changeset
    57
.TP 3
90ce3da70b43 Initial load
duke
parents:
diff changeset
    58
executable 
90ce3da70b43 Initial load
duke
parents:
diff changeset
    59
Java executable from which the core dump was produced. 
90ce3da70b43 Initial load
duke
parents:
diff changeset
    60
.br
90ce3da70b43 Initial load
duke
parents:
diff changeset
    61
.TP 3
90ce3da70b43 Initial load
duke
parents:
diff changeset
    62
core 
90ce3da70b43 Initial load
duke
parents:
diff changeset
    63
core file for which the stack trace is to be printed. 
90ce3da70b43 Initial load
duke
parents:
diff changeset
    64
.br
90ce3da70b43 Initial load
duke
parents:
diff changeset
    65
.TP 3
90ce3da70b43 Initial load
duke
parents:
diff changeset
    66
remote\-hostname\-or\-IP 
2692
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
    67
remote debug server's (see jsadebugd(1)) hostname or IP address. 
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    68
.br
90ce3da70b43 Initial load
duke
parents:
diff changeset
    69
.TP 3
90ce3da70b43 Initial load
duke
parents:
diff changeset
    70
server\-id 
90ce3da70b43 Initial load
duke
parents:
diff changeset
    71
optional unique id, if multiple debug servers are running on the same remote host. 
90ce3da70b43 Initial load
duke
parents:
diff changeset
    72
.RE
90ce3da70b43 Initial load
duke
parents:
diff changeset
    73
90ce3da70b43 Initial load
duke
parents:
diff changeset
    74
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    75
.SH "DESCRIPTION"
90ce3da70b43 Initial load
duke
parents:
diff changeset
    76
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    77
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    78
\f3jstack\fP prints Java stack traces of Java threads for a given Java process or core file or a remote debug server. For each Java frame, the full class name, method name, 'bci' (byte code index) and line number, if available, are printed. With the \-m option, jstack prints both Java and native frames of all threads along with the 'pc' (program counter). For each native frame, the closest native symbol to 'pc', if available, is printed. C++ mangled names are not demangled. To demangle C++ names, the output of this command may be piped to \f3c++filt\fP. If the given process is running on a 64\-bit VM, you may need to specify the \f2\-J\-d64\fP option, e.g.:
90ce3da70b43 Initial load
duke
parents:
diff changeset
    79
.br
90ce3da70b43 Initial load
duke
parents:
diff changeset
    80
90ce3da70b43 Initial load
duke
parents:
diff changeset
    81
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    82
.nf
90ce3da70b43 Initial load
duke
parents:
diff changeset
    83
\f3
90ce3da70b43 Initial load
duke
parents:
diff changeset
    84
.fl
90ce3da70b43 Initial load
duke
parents:
diff changeset
    85
jstack \-J\-d64 \-m pid
90ce3da70b43 Initial load
duke
parents:
diff changeset
    86
.fl
90ce3da70b43 Initial load
duke
parents:
diff changeset
    87
\fP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    88
.fi
90ce3da70b43 Initial load
duke
parents:
diff changeset
    89
90ce3da70b43 Initial load
duke
parents:
diff changeset
    90
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    91
.LP
2692
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
    92
\f3NOTE\fP \- This utility is unsupported and may or may not be available in future versions of the JDK. In Windows Systems where dbgeng.dll is not present, 'Debugging Tools For Windows' needs to be installed to have these tools working. Also, \f2PATH\fP environment variable should contain the location of \f2jvm.dll\fP used by the target process or the location from which the Crash Dump file was produced.
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    93
.LP
2692
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
    94
.LP
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
    95
For example, \f2set PATH=<jdk>\\jre\\bin\\client;%PATH%\fP
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
    96
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    97
.SH "OPTIONS"
90ce3da70b43 Initial load
duke
parents:
diff changeset
    98
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
    99
.RS 3
90ce3da70b43 Initial load
duke
parents:
diff changeset
   100
.TP 3
90ce3da70b43 Initial load
duke
parents:
diff changeset
   101
\-F 
2692
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
   102
Force a stack dump when 'jstack [\-l] pid' does not respond. 
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
   103
.TP 3
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
   104
\-l 
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
   105
Long listing. Prints additional information about locks such as list of owned java.util.concurrent 
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
   106
.na
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
   107
\f2ownable synchronizers\fP @
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
   108
.fi
9573
c02ff5a7c67b 7043684: Update man pages for JDK 7 tools
bpatel
parents: 5865
diff changeset
   109
http://download.oracle.com/javase/7/docs/api/java/util/concurrent/locks/AbstractOwnableSynchronizer.html. 
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   110
.TP 3
90ce3da70b43 Initial load
duke
parents:
diff changeset
   111
\-m 
90ce3da70b43 Initial load
duke
parents:
diff changeset
   112
prints mixed mode (both Java and native C/C++ frames) stack trace. 
90ce3da70b43 Initial load
duke
parents:
diff changeset
   113
.TP 3
90ce3da70b43 Initial load
duke
parents:
diff changeset
   114
\-h 
90ce3da70b43 Initial load
duke
parents:
diff changeset
   115
prints a help message.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   116
.br
90ce3da70b43 Initial load
duke
parents:
diff changeset
   117
.br
90ce3da70b43 Initial load
duke
parents:
diff changeset
   118
.TP 3
90ce3da70b43 Initial load
duke
parents:
diff changeset
   119
\-help 
90ce3da70b43 Initial load
duke
parents:
diff changeset
   120
prints a help message
90ce3da70b43 Initial load
duke
parents:
diff changeset
   121
.br
90ce3da70b43 Initial load
duke
parents:
diff changeset
   122
.RE
90ce3da70b43 Initial load
duke
parents:
diff changeset
   123
90ce3da70b43 Initial load
duke
parents:
diff changeset
   124
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
   125
.SH "SEE ALSO"
90ce3da70b43 Initial load
duke
parents:
diff changeset
   126
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
   127
.RS 3
90ce3da70b43 Initial load
duke
parents:
diff changeset
   128
.TP 2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   129
o
90ce3da70b43 Initial load
duke
parents:
diff changeset
   130
pstack(1) 
90ce3da70b43 Initial load
duke
parents:
diff changeset
   131
.TP 2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   132
o
90ce3da70b43 Initial load
duke
parents:
diff changeset
   133
c++filt(1) 
90ce3da70b43 Initial load
duke
parents:
diff changeset
   134
.TP 2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   135
o
2692
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
   136
jps(1) 
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   137
.TP 2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   138
o
2692
345bc8d65b19 6837214: Update JDK7 man pages
tbell
parents: 2
diff changeset
   139
jsadebugd(1) 
2
90ce3da70b43 Initial load
duke
parents:
diff changeset
   140
.RE
90ce3da70b43 Initial load
duke
parents:
diff changeset
   141
90ce3da70b43 Initial load
duke
parents:
diff changeset
   142
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
   143
.SH "KNOWN BUGS"
90ce3da70b43 Initial load
duke
parents:
diff changeset
   144
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
   145
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
   146
Mixed mode stack trace, the \-m option, does not work with the remote debug server.
90ce3da70b43 Initial load
duke
parents:
diff changeset
   147
.LP
90ce3da70b43 Initial load
duke
parents:
diff changeset
   148