unkillable process during core dump
Hello!
I have noticed that a process doing a core dump is unkillable. Now imagine that there are many such processes and they are large. An example:
#include <signal.h>
#include <stdlib.h>
#include <unistd.h>
int main() {
calloc(1000000000,1);
signal(SIGCLD,SIG_IGN);
while(1) {
if(fork()==0) {
raise(SIGABRT);
_exit(0);
}
sleep(10);
}
return 0;
}Try with large enough ulimit -c and with sysctl kernel.core_uses_pid=0. You kill the parent, but the children are still doing their core dumps.
Signature · 1 line
Alexander.