[lkml]   [2004]   [Feb]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: More waitpid issues with CLONE_DETACHED/CLONE_THREAD

    On Sat, 31 Jan 2004, Daniel Jacobowitz wrote:
    > >
    > > Can you verify that that process doesn't have any sub-threads? (Again,
    > > that should be easily visible in /proc/<pid>/task/).
    > It is quite easily visible - in fact, it's hilarious.
    > 8454 pts/8 Z 0:00 [linux-dp] <defunct>
    > drow@nevyn:~% ls /proc/8454
    > auxv cmdline cwd@ environ exe@ fd/ maps mem mounts root@ stat
    > drow@nevyn:~% ls /proc/8454/task
    > ls: /proc/8454/task: No such file or directory

    Oh damn. Yeah, we don't allow you to even see the threads in this case (it
    checks "pid_alive(task)". We don't want you to try to confuse things by
    opening files of processes that we think are dead.

    For the case of trying to figure out sub-threads of a dead thread group
    leader, that may actually be a bug.

    Just for testing this, you might remove the check for

    if (!pid_alive(task))
    goto out;

    in proc_pident_lookup() in fs/proc/base.c.

    Ingo - comments? We really want the sysadmin to be able to find threads
    that have a dead group leader, and right now that seems to be impossible.

    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at

     \ /
      Last update: 2009-11-18 23:46    [W:0.019 / U:17.924 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site