Issue
I started a java program in debug mode in eclipse and now I need the PID of its process in order to generate a Jmap snapshot. I tried with:
ps aux | grep 'eclipse'
ps aux | grep 'myServerName'
but no chance to find that PID.
Solution
if you have java/bin
in your path
then you can use java ps tool:
jps -l
Output:
17623 com.intellij.idea.Main
29003 sun.tools.jps.Jps
The first column is process id.
Answered By - Dmitry Zagorulkin
Answer Checked By - Clifford M. (JavaFixing Volunteer)