JPS is a small tool that the JDK provides to view the current Java process, and can be viewed as an abbreviation for the javavirtual Machine process Status tool. Very simple and practical.
Command format: JPS [options] [HostID]
Options option:
-Q: Only VM identifiers are output, excluding Classname,jar name,arguments in Main method
-m: Output parameter of Main method
-L: Output full package name, application main class name, jar full path name
-V: Output JVM parameters
-V: The output passes through the flag file to a parameter in the JVM (. hotspotrc file or a file specified by-xx:flags=)
-joption: Passing parameters to the VM, for example:-j-xms512m
[HostID]:
[Protocol:] [[//]hostname] [:p ORT] [/ServerName]
Output format of the command:
Lvmid [[classname| Jarfilename | "Unknown"] [arg*] [jvmarg*]]
1) JPS
2) Jps–l: Output main class or jar full path name
3) Jps–v: output JVM Parameters
4) Jps–q: Only show Java process number
5) jps-mlv10.134.68.173
Note: If you need to see JVM processes on other machines, you need to start jstatd on the machine you want to view.