1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

MDEV-28976: mtr must wait for server to actually die

do_shutdown_server(): Call wait_until_dead() also when we are forcibly
killing the process (timeout=0). We have evidence that killing
the process may take some time and cause mystery failures in
crash recovery tests. For InnoDB, several failures were observed between
commit da094188f6 and
commit 0ee1082bd2
when no advisory file locking was being used by default.
This commit is contained in:
Marko Mäkelä
2023-04-19 14:08:53 +03:00
parent feeeacc4d7
commit d665186477

View File

@@ -5191,7 +5191,7 @@ void do_shutdown_server(struct st_command *command)
if (timeout) if (timeout)
(void) my_kill(pid, SIGABRT); (void) my_kill(pid, SIGABRT);
/* Give server a few seconds to die in all cases */ /* Give server a few seconds to die in all cases */
if (!timeout || wait_until_dead(pid, timeout < 5 ? 5 : timeout)) if (wait_until_dead(pid, timeout < 5 ? 5 : timeout))
{ {
(void) my_kill(pid, SIGKILL); (void) my_kill(pid, SIGKILL);
} }