Hi Pierre,

On Mon, Oct 24, 2016 at 12:16:32PM +0000, Pierre Cheynier wrote:
> $ grep ^Sig /proc/43135/status
> SigQ:    0/192473
> SigPnd:    0000000000000000
> SigBlk:    0000000000000000
> SigIgn:    0000000000001000
> SigCgt:    0000000180004803
(...)

Same for all of them. Very interesting, SIGUSR2 (12) is set
in SigIgn :-)  One question is "why", but at least we know we
have a workaround consisiting in unblocking these signals in
haproxy-systemd-wrapper, as we did in haproxy.

Care to retry with the attached patch ?

Willy
diff --git a/src/haproxy-systemd-wrapper.c b/src/haproxy-systemd-wrapper.c
index d118ec6..f42723b 100644
--- a/src/haproxy-systemd-wrapper.c
+++ b/src/haproxy-systemd-wrapper.c
@@ -169,6 +169,14 @@ int main(int argc, char **argv)
 {
        int status;
        struct sigaction sa;
+       sigset_t blocked_sig;
+
+       /* Ensure signals are not blocked. Some shells or service managers may
+        * accidently block all of our signals unfortunately, causing lots of
+        * zombie processes to remain in the background during reloads.
+        */
+       sigemptyset(&blocked_sig);
+       sigprocmask(SIG_SETMASK, &blocked_sig, NULL);
 
        wrapper_argc = argc;
        wrapper_argv = argv;

Reply via email to