is there any way to kill Java process with name(returned with jps command) instead of PID?
1 Answer
Here is the command to kill the Java process by is Process Name instead of its ProcessID.
kill `jps | grep "DataNode" | cut -d " " -f 1`
2 Comments
Krishnom
This works well. Is there any command like
jps which can kill the java process just by specifying the Main class as argument to command. I am looking for a command like command kill <DataNode>Aakash Verma
Search for javaw.exe in Task Manager and from there you can kill it.. Otherwise try this
pkill -9 -f <nameOfYourJavaAplication>