]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Use SIGABRT instead of SIGKILL to produce cores on failed start
authorOndřej Surý <ondrej@isc.org>
Wed, 21 Apr 2021 13:39:14 +0000 (15:39 +0200)
committerMichal Nowak <mnowak@isc.org>
Tue, 4 May 2021 15:22:41 +0000 (17:22 +0200)
When the `named` would hang on startup it would be killed with SIGKILL
leaving us with no information about the state the process was in.
This commit changes the start.pl script to send SIGABRT instead, so we
can properly collect and process the coredump from the hung named
process.

(cherry picked from commit 861a236937268466f634392e6b300d349932fd96)

bin/tests/system/start.pl

index b54b0c5800be99fde693100d38645b95b76a9fb9..7738fa310ff263b6bb352cfead9738a5a9cc33ad 100755 (executable)
@@ -212,7 +212,7 @@ sub start_server {
                if (++$tries > 140) {
                        print "I:$test:Couldn't start server $command (pid=$child)\n";
                        print "I:$test:failed\n";
-                       system "kill -9 $child" if ("$child" ne "");
+                       kill "ABRT", $child if ("$child" ne "");
                        chdir "$testdir";
                        system "$PERL $topdir/stop.pl $test";
                        exit 1;