Messages in this thread | | | Date | Wed, 12 Nov 2008 16:05:55 +0100 | From | Oleg Nesterov <> | Subject | Re: Signals to cinit |
| |
On 11/10, sukadev@linux.vnet.ibm.com wrote: > > Also, what happens if a fatal signal is first received from a descendant > and while that is still pending, the same signal is received from ancestor > ns ? Won't the second one be ignored by legacy_queue() for the non-rt case ?
Please see my another email:
We must also change sig_ignored() to drop SIGKILL/SIGSTOP early when it comes from the same ns. Otherwise, it can mask the next SIGKILL from the parent ns.
But this perhaps makes sense anyway, even without containers. Currently, when the global init has the pending SIGKILL, we can't trust __wait_event_killable/etc, and this is actually wrong.
We can drop other SIG_DFL signals from the same namespace early as well. I seem to already did something like sig_init_ignored(), but I forgot.
Or, we can just ignore this (imho) minor problem. The ancestor ns must know it can't reliably kill cinit with (say) SIGTERM. It can be ignored, or it can have have a handler, and it can be lost because SIGTERM is already pending. Only SIGKILL is special.
Actually. I personally think that if we manage to achieve that
- the sub-namespace can't kill its init
- the ancestor can always kill cinit with SIGKILL
then imho we should not worry very much about other issues ;)
Oleg.
| |