The JPS command uses

Source: Internet
Author: User

JPS (Java Virtual machine process Status Tool) is a JDK1.5 provides a command to display all current Java process PID, simple and practical, very suitable for linux/ Simple view of the current Java process on the UNIX platform. Many people use the PS command in UNIX systems, which is used primarily to show the current system's progress, which processes and process IDs. The same is true of JPS, which shows the current system's Java process and process ID. We can use it to see how many Java processes we've started (because each Java program will have a single Java Virtual machine instance) and opt to see the detailed startup parameters for those processes.

How to use: in the current command line to hit JPS (JPS stored in the JAVA_HOME/BIN/JPS, in order to facilitate the use of the java_home/bin/to join the path).

$> JPS
23991 Jps
23651 Resin

Compare Common parameters:

-Q displays only the PID, does not display the class name, the jar file name, and the arguments passed to the main method
$> Jps-q
28680
23789
23651

-m output parameters passed to the main method, which may be null on the embedded JVM
$> jps-m
28715 jps-m
23789 Bossmain
23651 resin-socketwait 32768-stdout/resin/log/stdout.log-stderr/resin/log/stderr.log

-L OUTPUT The full package name of the main class of the application or the full path name of the application's jar file
$> jps-l
28729 Sun.tools.jps.Jps
23789 Com.asiainfo.aimc.bossbi.BossMain
23651 Com.caucho.server.resin.Resin

-V Output parameters passed to the JVM
$> jps-v
23789 Bossmain
28802 jps-denv.class.path=/data/aoxj/bossbi/twsecurity/java/trustwork140.jar:/data/aoxj/bossbi/twsecurity/java/ :/data/aoxj/bossbi/twsecurity/java/twcmcc.jar:/data/aoxj/jdk15/lib/rt.jar:/data/aoxj/jdk15/lib/tools.jar- Dapplication.home=/data/aoxj/jdk15-xms8m
23651 resin-xss1m-dresin.home=/data/aoxj/resin-dserver.root=/data/aoxj/resin-djava.util.logging.manager= Com.caucho.log.logmanagerimpl-djavax.management.builder.initial=com.caucho.jmx.mbeanserverbuilderimpl

Disclaimer: This article by the Swiftlet Net original compilation, reproduced please keep the link: JPS command use

The JPS command uses

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.