How to execute \"jps'' command on Windows

2019-07-20 15:33发布

问题:

I want to see my working java processes so I want to execute jps -m, but on my new Windows 8 machine there is this error message

Microsoft Windows [Version 6.3.9600]
(c) 2013 Microsoft Corporation. All rights reserved.

C:\Xelian>jps -m
'jps' is not recognized as an internal or external command,
operable program or batch file.

I have installed JDK

C:\Xelian>java -version
java version "1.7.0_67"
Java(TM) SE Runtime Environment (build 1.7.0_67-b01)
Java HotSpot(TM) 64-Bit Server VM (build 24.65-b04, mixed mode)

And another question? How to kill all java processes killall java works on Linux but on Windows 8?

回答1:

This is probably a case of the JDK's bin directory not being in your PATH. Try to put it in your path. see this other stack overflow question for more details. The directions are the pretty much the same for windows 8

Stack Overflow Answer