MySQL Lists are EOL. Please join:

List:Commits« Previous MessageNext Message »
From:Davi Arnaut Date:September 29 2010 6:36pm
Subject:Re: bzr commit into mysql-5.5-bugfixing branch (davi:3208) Bug#49938
View as plain text  
Hi Sergei,

On 9/29/10 2:51 AM, Sergei Golubchik wrote:
> Hi, Davi!
>
> On Sep 29, Davi Arnaut wrote:
>> # At a local mysql-5.5-bugfixing repository of davi
>>
>>   3208 Davi Arnaut	2010-09-29
>>     Bug#49938: Failing assertion: inode or deadlock in fsp/fsp0fsp.c
>>
>>     The problem was that, for storage engines that do not support
>>     truncate table via drop and recreate, the delete_all_rows
>>     method could be invoked with a shared metadata lock, causing
>>     problems if the engine needed exclusive access to some internal
>>     metadata. This problem originated with the fact that there is
>>     no truncate specific handler method, which ended up leading
>>     to a abuse of the delete_all_rows method that is primarily
>>     used for delete operations without a condition.
>
> delete_all_rows() should always be fine with a shared metadata lock.
> Why would innodb expect an exclusive lock here?
>

InnoDB does a internal drop and recreate. The intention of this new 
truncate method is exactly this, allow certain engines to internally 
drop and recreate its tables, without complicating delete_all_rows which 
at this point becomes confined to delete statements.

As a further clean up, truncate no longer has anything to do with the 
delete or truncate partition paths. To keep truncate partition working, 
I've mapped the truncate to delete_all_rows in the appropriate engines. 
This also allowed the simplification of some code in the ha_partition.

The patch is still in progress. Will commit a new version later today.

Regards,

Davi
Thread
bzr commit into mysql-5.5-bugfixing branch (davi:3208) Bug#49938Davi Arnaut29 Sep
Re: bzr commit into mysql-5.5-bugfixing branch (davi:3208)Bug#49938Sergei Golubchik29 Sep
  • Re: bzr commit into mysql-5.5-bugfixing branch (davi:3208) Bug#49938Davi Arnaut29 Sep
    • Re: bzr commit into mysql-5.5-bugfixing branch (davi:3208)Bug#49938Sergei Golubchik30 Sep
      • Re: bzr commit into mysql-5.5-bugfixing branch (davi:3208) Bug#49938Davi Arnaut30 Sep