lkml.org 
[lkml]   [2002]   [Dec]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: Destroying processes
From
Date
On Wed, 2002-12-11 at 14:01, Justin Hibbits wrote:

> Is there a system call that would destroy a process? Sometimes I end up with
> zombie processes, other times I end up with a process attaching to a device
> driver, and hanging, so I want to be able to completely destroy the
> process...image, file handle, driver hooks, everything. If there isn't one,
> and noone wants to do it, I'll gladly do it (may take a few weeks tho). I just
> don't wanna do what someone else has already done.

Cases where kill -9 fail to work are cases where it is supposed to fail.

You cannot kill zombies, that would break POSIX compliance when the
parent's called wait. If you task's parents are not properly calling
wait() that is an application bug. If the parent exits, the children
should be reparented to init and init will reap them via wait().

You also cannot kill tasks that are sleeping (D in ps/top). They may
hold a semaphore or otherwise be in the middle of a critical section.
Killing them would be bad bad bad.

Robert Love

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:31    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site