home *** CD-ROM | disk | FTP | other *** search
- Xref: sparky comp.unix.programmer:4289 comp.unix.misc:3224
- Path: sparky!uunet!cis.ohio-state.edu!pacific.mps.ohio-state.edu!linac!uwm.edu!ogicse!orstcs!orstcs!usenetusenet
- From: herberj@prism.CS.ORST.EDU (John Wesley Herberg)
- Newsgroups: comp.unix.programmer,comp.unix.misc
- Subject: Process & Signal Question
- Message-ID: <1992Aug14.013450.9864@CS.ORST.EDU>
- Date: 14 Aug 92 01:34:50 GMT
- Article-I.D.: CS.1992Aug14.013450.9864
- Sender: usenet@CS.ORST.EDU
- Organization: Oregon State University, Computer Science Dept.
- Lines: 20
- Nntp-Posting-Host: prism.cs.orst.edu
-
-
- 1 - Is there an effecient way for one process to know if another is running
- when the only thing you know about it is its name. The way I'm doing it now
- is grabbing info for all the processes by using pstat(an HP-UX call) &
- searching through that info for a matching process name. Is there some type
- of call I could do on the executable to see if it is in use. I noticed
- make doesn't allow you to update a file when its being used - how does it know?
-
- 2 - In Marc Rochkind's "Advanced Unix Programming", he says it's not a good
- idea to use the SIGUSR1/2 signals for user defined signals. Why? All I want
- to do is notify another process of an event & I don't want the overhead of a
- msg, shared mem, etc. Seems to me this would be the most effecient way. Is
- there something else I should know about using signals?
-
- BTW, I am working on HP-UX.
-
- Any help much appreciated,
- --
- -----------------------------------------------------------------------
- John W. Herberg Internet: herberj@prism.cs.orst.edu
-