Bug #33564 Backup: deadlock during restore
Submitted: 29 Dec 2007 0:10 Modified: 7 Oct 2008 10:13
Reporter: Peter Gulutzan Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Server: Backup Severity:S3 (Non-critical)
Version:6.0.5-alpha-debug OS:Linux (SUSE 10 64-bit)
Assigned to: Øystein Grøvlen CPU Architecture:Any

[29 Dec 2007 0:10] Peter Gulutzan
Description:
I use two connections.
With the first connection, I lock a Falcon table.
With the second connection, I try to update the table. Hangs.
With the first connection, I try to restore the database. Hangs.

Built from mysql-6.0-backup source with BUILD/compile-pentium-debug-max.
Last changeset = "ChangeSet@1.2753, 2007-12-20 15:32:22-05:00".

How to repeat:
Start two mysql client connections. Call them T1 and T2.

On T1, say:
create database w;
use w
create table ti (s1 int) engine=falcon;
backup database w to '/usr/local/mysql/var/t11';
set @@autocommit=0;
insert into ti values (1);
commit;
update ti set s1 = 2;

On T2, say:
set @@autocommit=0;
use w
update ti set s1 = 2; /* hangs */

On T1, say:
restore from '/usr/local/mysql/var/t11'; /* hangs */

So I have deadlock with Falcon tables.
To end the deadlock, I try:

On T1, say:
^C i.e. control-C
rollback;       /* but t2 still hangs */
show processlist; /* to get process number of T2 */
kill (t2 process number); /* fails */
quit
mysqladmin shutdown ... still fails!
I have to 'kill -9' to escape.
[29 Dec 2007 5:30] MySQL Verification Team
Thank you for the bug report. Verified as described.
[7 Oct 2008 10:13] Øystein Grøvlen
Not able to reproduce anymore.
Restore does not hang when I do this on the current backup team tree.