List:Commits« Previous MessageNext Message »
From:Konstantin Osipov Date:July 27 2007 12:22pm
Subject:Re: bk commit into 5.1 tree (anozdrin:1.2561) BUG#28030
View as plain text  
* Alexander Nozdrin <alik@stripped> [07/07/26 21:21]:
> ChangeSet@stripped, 2007-07-26 21:08:00+04:00, anozdrin@ibm. +4 -0
>   Fix for BUG#28030: test im_instance_conf fails with an assert.
>   
>   The problem was a race condition on shutdown -- when IM got shutdown
>   request while a guarded mysqld is starting. In this case the Guardian
>   thread tried to stop the mysqld, but might fail if the mysqld hadn't
>   created pid-file so far. When this happened, the mysqld-monitor thread
>   didn't stop, so the assert in Thread_registry happened.
>   
>   The fix is to make several attempts to stop mysqld if it is active.

Sigh. Could you at least limit the number of attempts?
OK to push.

> -    instance->kill_mysqld(SIGTERM);
> +    while (true)
> +    {
> +      if (!instance->kill_mysqld(SIGTERM))
> +        break;
> +
> +      if (!instance->is_active())
> +        break;
> +
> +      /* Sleep for 0.3 sec and check again. */
> +
> +      my_sleep(300000);
> +    }
>  

-- 
-- Konstantin Osipov              Software Developer, Moscow, Russia
-- MySQL AB, www.mysql.com   The best DATABASE COMPANY in the GALAXY
Thread
bk commit into 5.1 tree (anozdrin:1.2561) BUG#28030Alexander Nozdrin26 Jul
  • Re: bk commit into 5.1 tree (anozdrin:1.2561) BUG#28030Konstantin Osipov26 Jul
  • Re: bk commit into 5.1 tree (anozdrin:1.2561) BUG#28030Konstantin Osipov27 Jul