diff --git a/sysctl.d/50-coredump.conf.in b/sysctl.d/50-coredump.conf.in index da76fd71d6..4338756efd 100644 --- a/sysctl.d/50-coredump.conf.in +++ b/sysctl.d/50-coredump.conf.in @@ -15,6 +15,17 @@ # See systemd-coredump(8) and core(5). kernel.core_pattern=|@rootlibexecdir@/systemd-coredump %P %u %g %s %t %c %h +# Allow that 16 coredumps are dispatched in parallel by the kernel. We want to +# be able to collect process metadata from /proc/%P/ while processing +# coredumps, and thus need to make sure the crashed processes are not reaped +# until we finished collecting what we need. The kernel default for this sysctl +# is "0" which means the kernel doesn't wait for userspace processes to finish +# processing before reaping the crashed processes — by setting this higher the +# kernel will delay reaping until we are done, but only for the specified +# number of crashes in parallel. The value of 16 is chosen to match +# systemd-coredump.socket's MaxConnections= value. +kernel.core_pipe_limit=16 + # Also dump processes executing a set-user-ID/set-group-ID program that is # owned by a user/group other than the real user/group ID of the process, or # a program that has file capabilities. ("2" is called "suidsafe" in core(5)).