Detecting if Linux Program Running
Constantinos A. Kotsokalis
c.kotsokalis at noc.ntua.gr
Sat Mar 18 15:42:58 EST 2000
On Sat, 18 Mar 2000 20:03:29 GMT, Joseph C. Kopec wrote:
>Is there any easy way using Python under Linux to detect whether a
>particular executable is running? Thanks in advance.
The easiest but not reliable way should be lock files (i.e.
files you usually find under /var/run). Process creates file,
process checks for file, story goes on. Actually this technique
is practiced by a whole lot of applications no matter if they
are written in Python or some other language.
I repeat though, it's not a reliable method.
--
Constantinos A. Kotsokalis || c.kotsokalis at noc.ntua.gr
National Technical University of Athens
Network Management Center
Tel. No: +30 1 7721861
More information about the Python-list
mailing list