Path: utzoo!attcan!uunet!cs.utexas.edu!usc!apple!voder!nsc!taux01!tasu17!yval From: yval@tasu17.UUCP (Yuval Yarom) Newsgroups: comp.unix.questions Subject: Re: How to find process name in c? Message-ID: <4210@taux01.nsc.com> Date: 18 Jul 90 16:41:31 GMT References: <23896@adm.BRL.MIL> Sender: netnews@taux01.nsc.com Reply-To: yval@tasu17.UUCP (Yuval Yarom) Organization: National Semiconductor (IC) Ltd, Israel Lines: 29 In article <23896@adm.BRL.MIL> konczal@mail-gw.ncsl.nist.gov (Joseph C. Konczal) writes: | | From: "Conor P. Cahill" | Date: 15 Jul 90 01:59:57 GMT | | An easy way to see if a particular executable is running is to try | to open the file with write permissions. If you get the errno ETXTBSY, | the executable is being run. | |Where does this happen, what kind of Unix? I have overwritten |executable files that are currently running under various revisions of |BSD, SunOS, even VMS, without ever getting errno ETXTBSY. After the |image is loaded into core, why should the OS care what you do to the |copy still on disk? ETXTBSY is not even listed in the `Errors' |section of the SunOS `open' man page. | |--Joe Konczal konczal@mail-gw.ncsl.nist.gov It seems that ETXTBSY does not appear in the SunOS manuals, but it does work (at least here). I think that this featureis not documented because it works only if the executable is running on the local machine. -- Yuval Yarom yval@taux01.nsc.com