Path: utzoo!attcan!uunet!husc6!mailrus!purdue!decwrl!ucbvax!GREMLIN.NRTC.NORTHROP.COM!willson From: willson@GREMLIN.NRTC.NORTHROP.COM (S H Willson) Newsgroups: comp.sys.sgi Subject: Re: Killing mex Message-ID: <8811171715.aa23937@SMOKE.BRL.MIL> Date: 17 Nov 88 22:14:17 GMT Sender: daemon@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 24 How can I kill mex automatically when logging out (like something in the .logout file) ? If mex is left running, anyone can come along and start a new shell as the old user -- doesn't this seem to be a real problem ?! Thanx Here is a copy of my .logout. It does what you want provided you don't have any extra text windows around (i.e., more than the console window). -- cut here -- if ($term == wsiris) clear ismex if ($status == 1 && `tty` == "/dev/console") then # Kill off mex the hard way # This still doesn't get rid of any textports! *Sigh* (sleep 2; kill -9 ` ps x | grep 'mex$' | awk '{print $1}' `) & endif echo -n "logout " $user " "; date; -- cut here -- Stephen Willson Northrop Research and Technology Center Palos Verdes, CA 90274