coredump: turn off coredump collection entirely after journald or PID 1 crashed
Safe is safe, let's turn off the whole logic if we can, after all it is unlikely we'll be able to process further crashes in a reasonable way.
This commit is contained in:
parent
78f043f77b
commit
5157879b75
|
@ -920,6 +920,9 @@ static int process_special_crash(const char *context[], int input_fd) {
|
|||
|
||||
log_notice("Detected coredump of the journal daemon or PID 1, diverted to %s.", filename);
|
||||
|
||||
log_notice("Due to the special circumstances, coredump collection will now be turned off.");
|
||||
(void) write_string_file("/proc/sys/kernel/core_pattern", "|/bin/false", 0);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue