if you have java/bin in your path then you can use java ps tool: jps -l
java/bin
path
jps -l
Output:17623 com.intellij.idea.Main29003 sun.tools.jps.Jps
The first column is process id.
Try ps aux | grep java, using 'java' as filter should show it.
ps aux | grep java