1JHSDB(1)                         JDK Commands                         JHSDB(1)
2
3
4

NAME

6       jhsdb - attach to a Java process or launch a postmortem debugger to an‐
7       alyze the content of a core dump from a crashed  Java  Virtual  Machine
8       (JVM)
9

SYNOPSIS

11       jhsdb clhsdb [--pid pid | --exe executable --core coredump]
12
13       jhsdb hsdb [--pid pid | --exe executable --core coredump]
14
15       jhsdb debugd (--pid pid | --exe executable --core coredump) [options]
16
17       jhsdb  jstack (--pid pid | --exe executable --core coredump | --connect
18       [server-id@]debugd-host) [options]
19
20       jhsdb jmap (--pid pid | --exe executable --core  coredump  |  --connect
21       [server-id@]debugd-host) [options]
22
23       jhsdb  jinfo  (--pid pid | --exe executable --core coredump | --connect
24       [server-id@]debugd-host) [options]
25
26       jhsdb jsnap (--pid pid | --exe executable --core coredump  |  --connect
27       [server-id@]debugd-host) [options]
28
29       pid    The  process  ID  to  which  the  jhsdb tool should attach.  The
30              process must be a Java process.  To get a list of Java processes
31              running on a machine, use the ps command or, if the JVM process‐
32              es are not running in a separate docker instance, the  jps  com‐
33              mand.
34
35              Note: JDK 10 has added support for using the Attach API when at‐
36              taching to Java processes running in a separate docker  process.
37              However,  the  jps  command will not list the JVM processes that
38              are running in a separate docker instance.  If you are trying to
39              connect  a Linux host with a Virtual Machine that is in a docker
40              container, you must use tools such as ps to look up the  PID  of
41              the JVM.
42
43       executable
44              The Java executable file from which the core dump was produced.
45
46       coredump
47              The core file to which the jhsdb tool should attach.
48
49       [server-id@]debugd-host
50              An optional server ID and the address of the remote debug server
51              (debugd).
52
53       options
54              The command-line options for a jhsdb mode.  See Options for  the
55              debugd  Mode,  Options for the jstack Mode, Options for the jmap
56              Mode, Options for the jinfo Mode,  and  Options  for  the  jsnap
57              Mode.
58
59       Note:
60
61       Either  the  pid or the pair of executable and core files or the [serv‐
62       er-id@]debugd-host must be provided for debugd, jstack, jmap, jinfo and
63       jsnap modes.
64

DESCRIPTION

66       You  can  use the jhsdb tool to attach to a Java process or to launch a
67       postmortem debugger to analyze  the  content  of  a  core-dump  from  a
68       crashed  Java  Virtual Machine (JVM).  This command is experimental and
69       unsupported.
70
71       Note:
72
73       Attaching the jhsdb tool to a live process will cause  the  process  to
74       hang and the process will probably crash when the debugger detaches.
75
76       The jhsdb tool can be launched in any one of the following modes:
77
78       jhsdb clhsdb
79              Starts the interactive command-line debugger.
80
81       jhsdb hsdb
82              Starts the interactive GUI debugger.
83
84       jhsdb debugd
85              Starts the remote debug server.
86
87       jhsdb jstack
88              Prints stack and locks information.
89
90       jhsdb jmap
91              Prints heap information.
92
93       jhsdb jinfo
94              Prints basic JVM information.
95
96       jhsdb jsnap
97              Prints performance counter information.
98
99       jhsdb command --help
100              Displays the options available for the command.
101

OPTIONS FOR THE DEBUGD MODE

103       --serverid server-id
104              An  optional  unique ID for this debug server.  This is required
105              if multiple debug servers are run on the same machine.
106

OPTIONS FOR THE JINFO MODE

108       --flags
109              Prints the VM flags.
110
111       --sysprops
112              Prints the Java system properties.
113
114       no option
115              Prints the VM flags and the Java system properties.
116

OPTIONS FOR THE JMAP MODE

118       no option
119              Prints the same information as Solaris pmap.
120
121       --heap Prints the java heap summary.
122
123       --binaryheap
124              Dumps the java heap in hprof binary format.
125
126       --dumpfile name
127              The name of the dumpfile.
128
129       --histo
130              Prints the histogram of java object heap.
131
132       --clstats
133              Prints the class loader statistics.
134
135       --finalizerinfo
136              Prints the information on objects awaiting finalization.
137

OPTIONS FOR THE JSTACK MODE

139       --locks
140              Prints the java.util.concurrent locks information.
141
142       --mixed
143              Attempts to print both java and native frames  if  the  platform
144              allows it.
145

OPTIONS FOR THE JSNAP MODE

147       --all  Prints all performance counters.
148
149
150
151JDK 14                               2020                             JHSDB(1)
Impressum