Subj : Stopping Program under LinuxThreads To : comp.programming.threads From : PC Date : Thu Sep 01 2005 05:29 am Hello! I have a threaded server that works fine under NPTL, but when I move it to a Linux 2.4.31 system that uses LinuxThreads, I'm running into a problem. What happens is that the init script loops for a while and eventually reports failure when I use it to stop the server daemon. What I think is happening is that, when the program starts up, LinuxThreads invisibly starts up a "manager thread" as a child of the main program, and apparently it sets the signal mask for this child process to block SIGTERM. The problem is that killproc tries to kill child processes first, so it sends a TERM to the manager thread, which happily ignores it. This causes killproc to loop, and to record an error. Later on, when it kills the parent process, the child does die, so in the end everything is OK, but it takes time and the "FAILURE" warning disturbs people. Is there a way around this? Any way to set the signal mask on the manager thread? Or is there some other scheme that will help a LinuxThreads program be terminated gracefully? Thanks! .