Path: utzoo!attcan!uunet!mcsun!ukc!uos-ee!celvin From: celvin@EE.Surrey.Ac.UK (Chris Elvin) Newsgroups: comp.unix.wizards Subject: Re: Phantom CPU gobbler?! Message-ID: <1990Jul3.092952.1003@EE.Surrey.Ac.UK> Date: 3 Jul 90 09:29:52 GMT References: <960004@teecs.UUCP> Organization: University of Surrey, Guildford, Surrey, UK. GU2 5XH Lines: 30 In article <960004@teecs.UUCP> belkin@teecs.UUCP (Hershel Belkin) writes: >I have what appears to me to be a strange situation which occasionally >occurs on my system. If anyone can shed some light on what may be >happenning, I'd appreciate some e-mail! ... > >Every so often I fins a shell process (sh or ksh) which has somehow >become dis-associated with its logon session. By this I mean that >the shell's PPID is "1", and the user is no longer logged on. My guess is that the user has written a shell script which he/she kick off as a background job. The script is a loop so never terminates. When the user logs off, the script is not killed, but its PPID is changed to 1 because its parent (the user's login shell) dies. This is the case for SUNOS 4.0.3 and I suspect that its pretty general for all dialects of *NIX I have experienced such scripts by users checking every 5 seconds whether their 'friends' are logged in. I positively discourage this sort of script and show the users how to kill the script automatically on logout and to leave a longer 'sleep time' in the loop. Hope this helps Chris -- Chris Elvin C.Elvin@EE.Surrey.Ac.UK "what happens if I press this big red button" Dept of Elec. Eng, University of Surrey, Guildford, Surrey, GU2 5XH. England