Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!think.com!mintaka!bloom-picayune.mit.edu!athena.mit.edu!jik From: jik@athena.mit.edu (Jonathan I. Kamens) Newsgroups: comp.unix.programmer Subject: Re: Waiting on parents and reinstating HUP Keywords: csh, parent, HUP Message-ID: <1991Apr24.215112.24695@athena.mit.edu> Date: 24 Apr 91 21:51:12 GMT References: <1991Apr23.144516.23119@news.miami.edu> <1991Apr24.150154.19539@minyos.xx.rmit.oz.au> Sender: news@athena.mit.edu (News system) Organization: Massachusetts Institute of Technology Lines: 22 In article <1991Apr24.150154.19539@minyos.xx.rmit.oz.au>, s902255@minyos.xx.rmit.oz.au (Andrew Vanderstock) writes: |> Best way to ensure that all processes die when a user logs out is to |> alias logout to 'kill -1 -9'. Are you sure you don't mean 'kill -9 -1'. I don't know of any system that treats '-9' as a special PID, but I know '-1' works on many systems. And isn't it better to use 'kill -HUP -1'? If the original user was trying to guarantee that background processes got HUP signals, it seems silly me to use signals that are stronger than the HUP signal. Finally, note that, as far as I know, using that will guarantee a signal delivered to every process owned by the user *except* the process from which the signal was sent. If he's using a login shell with a built-in 'kill', this means that his login shell won't get the signal and he won't be logged out. You have to be careful about this. -- Jonathan Kamens USnail: MIT Project Athena 11 Ashford Terrace jik@Athena.MIT.EDU Allston, MA 02134 Office: 617-253-8085 Home: 617-782-0710