jdk.jcmd/sun.tools.jmap.JMap - "jmap" Command


How to run "jmap" command from JDK lib\modules JImage file?

✍: FYIcenter


"jmap" command allows you to run the JVM heap memory tool.

"jmap" command is supported by the jmods\jdk.jcmd.jmod module file, which is also linked into the lib\modules JImage file in.

You can run the "jmap" command using the lib\modules JImage file as described below:

fyicenter> %JDK_HOME%\bin\java --module jdk.jcmd/sun.tools.jmap.JMap

    jinfo <option> <pid>
       (to connect to a running process)

where <option> is one of:
    -flag <name>         to print the value of the named VM flag
    -flag [+|-]<name>    to enable or disable the named VM flag
    -flag <name>=<value> to set the named VM flag to the given value
    -flags               to print VM flags
    -sysprops            to print Java system properties
    <no option>          to print both VM flags and system properties
    -? | -h | --help | -help to print this help message


jdk.jcmd/sun.tools.jps.Jps - "jps" Command

jdk.jcmd/sun.tools.jinfo.JInfo - "jinfo" Command

Tools Supported from JDK 9+ lib\modules JImage

⇑⇑ FAQ for JDK (Java Development Kit)

2019-09-16, 1448🔥, 0💬