[plug] GDM hanging, leaving zombies

Craig Ringer craig at postnewspapers.com.au
Mon Oct 20 15:57:14 WST 2003


> Are you sure it wasn't in the T state prior to your attempt to use
> strace, etc?

Yes ; I checked. It was in normal sleep - 'S'.

> If it were, that would explain everything (other than how
> it got into the T state in the first place). Have you `kill -CONT 24242`
> to get it going again? (Otherwise, there's no chance it's going to even
> be able to try to process new requests.)

I hadn't, no. Having now done so, there's no change - still as dead to 
the world as before.

>>If anybody knows how to get more inforamation from processes behaving 
>>like this, I'd love to hear it.
> 
> In some OSes I'm sure you don't need to trace the process to view its
> execution stack (i.e. doesn't matter that it's in the T state).

I wouldn't have the foggiest about how to do it, however. The methods I 
know are attaching gdb and doing a backtrace, or backtracing a core file 
after killing the process. Since gdb doesn't seem to want to attach, 
that's out, and by the time I can get a core it's a bit late anyway :-(

If there's a way to cause a process to dump core without dying, I'd be 
interested to hear it. As you may have guessed, I don't do this sort of 
stuff much.

There is the /proc/$PID/mem file, but I haven't the foggiest how to make 
any use of it.

>>The other issue is whether I can kill the parent and have the children 
>>survive. [snip]
> 
> Is there a way to take the child processes out of the process group
> (i.e. the parent process is probably the process group leader for the
> children). I don't know if there's a command-line util to do this, but
> presumably a quick C hack (when run as root) would do the trick (maybe
> not in Linux, though -- not sure).

I've done a bit more checking, and it doesn't look good. The children 
are connected by a pipe to the parent, and have not been reparented to 
init. I think that killing the parent is likely to send a SIGPIPE, to 
which the child will most likely respond by dying. Without going digging 
in gdm2 source code I can't be sure, but I'd say it's not designed to 
allow this.

Craig Ringer


_______________________________________________
plug mailing list
plug at plug.linux.org.au
http://mail.plug.linux.org.au/cgi-bin/mailman/listinfo/plug


More information about the plug mailing list