Does Python have a tool to list python processes similar to Java’s jps (http://docs.oracle.com/javase/6/docs/technotes/tools/share/jps.html)?
Edit:
Getting the pid’s of python processes is relatively easy (ps -A | grep python).
What I am really looking for is a way to query a currently-running python process and find out the python file it was originally executed on.
From the JPS docs, “jps will list each Java application’s lvmid followed by the short form of the application’s class name or jar file name.” Basically, is there an easy way to query a bunch of python processes and find out useful information like JPS does for JVMs?
The best way I’ve found to get the information I need is using
ps -x, which gives the original command line arguments of all running processes.