.\" Copyright (c) 2004, 2018, Oracle and/or its affiliates. All rights reserved. .\" DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. .\" .\" This code is free software; you can redistribute it and/or modify it .\" under the terms of the GNU General Public License version 2 only, as .\" published by the Free Software Foundation. .\" .\" This code is distributed in the hope that it will be useful, but WITHOUT .\" ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or .\" FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License .\" version 2 for more details (a copy is included in the LICENSE file that .\" accompanied this code). .\" .\" You should have received a copy of the GNU General Public License version .\" 2 along with this work; if not, write to the Free Software Foundation, .\" Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. .\" .\" Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA .\" or visit www.oracle.com if you need additional information or have any .\" questions. .\" .\" Automatically generated by Pandoc 2.3.1 .\" .TH "JMAP" "1" "2021" "JDK 17" "JDK Commands" .hy .SH NAME .PP jmap \- print details of a specified process .SH SYNOPSIS .PP \f[B]Note:\f[R] This command is experimental and unsupported. .PP \f[CB]jmap\f[R] [\f[I]options\f[R]] \f[I]pid\f[R] .TP .B \f[I]options\f[R] This represents the \f[CB]jmap\f[R] command\-line options. See \f[B]Options for the jmap Command\f[R]. .RS .RE .TP .B \f[I]pid\f[R] The process ID for which the information specified by the \f[I]options\f[R] is to be printed. The process must be a Java process. To get a list of Java processes running on a machine, use either the \f[CB]ps\f[R] command or, if the JVM processes are not running in a separate docker instance, the \f[B]jps\f[R] command. .RS .RE .SH DESCRIPTION .PP The \f[CB]jmap\f[R] command prints details of a specified running process. .PP \f[B]Note:\f[R] .PP This command is unsupported and might not be available in future releases of the JDK. On Windows Systems where the \f[CB]dbgeng.dll\f[R] file isn\[aq]t present, the Debugging Tools for Windows must be installed to make these tools work. The \f[CB]PATH\f[R] environment variable should contain the location of the \f[CB]jvm.dll\f[R] file that\[aq]s used by the target process or the location from which the core dump file was produced. .SH OPTIONS FOR THE JMAP COMMAND .TP .B \f[CB]\-clstats\f[R] \f[I]pid\f[R] Connects to a running process and prints class loader statistics of Java heap. .RS .RE .TP .B \f[CB]\-finalizerinfo\f[R] \f[I]pid\f[R] Connects to a running process and prints information on objects awaiting finalization. .RS .RE .TP .B \f[CB]\-histo\f[R][\f[CB]:live\f[R]] \f[I]pid\f[R] Connects to a running process and prints a histogram of the Java object heap. If the \f[CB]live\f[R] suboption is specified, it then counts only live objects. .RS .RE .TP .B \f[CB]\-dump:\f[R]\f[I]dump_options\f[R] \f[I]pid\f[R] Connects to a running process and dumps the Java heap. The \f[I]dump_options\f[R] include: .RS .IP \[bu] 2 \f[CB]live\f[R] \-\-\- When specified, dumps only the live objects; if not specified, then dumps all objects in the heap. .IP \[bu] 2 \f[CB]format=b\f[R] \-\-\- Dumps the Java heap in \f[CB]hprof\f[R] binary format .IP \[bu] 2 \f[CB]file=\f[R]\f[I]filename\f[R] \-\-\- Dumps the heap to \f[I]filename\f[R] .PP Example: \f[CB]jmap\ \-dump:live,format=b,file=heap.bin\f[R] \f[I]pid\f[R] .RE