How to find out the pid of a running program?
bowman
bowman at montana.com
Sun Aug 1 10:42:24 EDT 1999
Peter Torstenson wrote:
>
> I want to find out the pid of another program than the one I give
> the command from!
How about os.popen("ps -ef") or whatever works on your OS. You can then
search
for 'pppd' and get its pid. Not a great solution, as 'ps' flags and
formats vary across platforms. OTOH, is you needed to know the owner of
the process or other info, you'd get it all in one shot.
--
Bear Technology Making Montana safe for Grizzlies
http://people.montana.com/~bowman/
More information about the Python-list
mailing list