Skip to main content

Timeline for Kill all descendant processes

Current License: CC BY-SA 3.0

12 events
when toggle format what by license comment
Apr 10, 2014 at 22:51 comment added mikeserv @Gilles The only way I can think to do it is something like my call to $(grep) at the bottom to do so at child process launch. At least, the only way without using a container of some kind. And even that only ensures I know about the children $pids - their children and so on could easily slip out.
Apr 10, 2014 at 22:45 comment added mikeserv @Gilles - Agreed! Is there a solution here that handles that?
Apr 10, 2014 at 22:44 comment added Gilles 'SO- stop being evil' I don't see what your latest edits change. Suppose that P forks Q, then Q forks R, then Q exits, then your code runs. Nothing that you do will identify R as a descendant of P.
Apr 10, 2014 at 22:42 comment added mikeserv @Gilles and now I think I also get all processes claiming the initial as the PPid. Probably it's redundant, but I'm not sure.
Apr 10, 2014 at 22:39 history edited mikeserv CC BY-SA 3.0
added 43 characters in body
Apr 10, 2014 at 22:29 comment added mikeserv @Gilles - thank you. I've alleviated that somewhat, but, still, the only sure way to handle this is with namespaces or some other kind of container. Or so I think, anyway.
Apr 10, 2014 at 22:28 history edited mikeserv CC BY-SA 3.0
added 104 characters in body
Apr 10, 2014 at 22:19 comment added Gilles 'SO- stop being evil' This misses all cases where a child dies before the grandchild.
Apr 10, 2014 at 19:25 history edited mikeserv CC BY-SA 3.0
deleted 6 characters in body
Apr 10, 2014 at 18:15 history edited mikeserv CC BY-SA 3.0
added 23 characters in body
Apr 10, 2014 at 16:46 history edited mikeserv CC BY-SA 3.0
added 155 characters in body
Apr 10, 2014 at 16:04 history answered mikeserv CC BY-SA 3.0