Bug #52020 InnoDB can still deadlock on just INSERT...ON DUPLICATE KEY
Submitted: 12 Mar 2010 21:49 Modified: 4 Jan 2012 21:39
Reporter: Harrison Fisk Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: InnoDB storage engine Severity:S3 (Non-critical)
Version:5.0, 5.1.46 OS:Any
Assigned to: Marko Mäkelä CPU Architecture:Any

File: Maximum allowed size is 50MB.
Description:
Privacy:

If the data you need to attach is more than 50MB, you should create a compressed archive of the data, split it to 50MB chunks, and upload each of them as a separate attachment.

To split a large file:

[13 Mar 2010 15:25] Valeriy Kravchuk
Multithreaded test case (no luck in repeating though)

Attachment: bug52020.c (text/x-csrc), 6.11 KiB.

[17 Mar 2010 17:51] SINISA MILIVOJEVIC
test script that also failed repeating the bug

Attachment: sinisa.test (application/octet-stream, text), 1.42 KiB.

[17 Mar 2010 18:03] SINISA MILIVOJEVIC
New version with four threads ....

Attachment: sinisa4.test (application/octet-stream, text), 1.94 KiB.

[21 Apr 2010 7:56] Shane Bester
think i repeated it now.. please , check if it looks correct.

Attachment: bug52020_5.4.3_deadlock_repeated.txt (text/plain), 2.52 KiB.

[21 Apr 2010 9:35] Shane Bester
think I repeated with 5.1.45 and insert .. on duplicate key update, see attached.

Attachment: bug52020_5.1.45_deadlock_repeated.txt (text/plain), 3.13 KiB.

[21 Apr 2010 15:01] Shane Bester
testcase to cause the above deadlock. often manually inspect 'show innodb status'  (it shows other deadlocks mostly :()

Attachment: bug52020_sbester.c (text/plain), 6.27 KiB.

[22 Dec 2017 8:22] Nitin Sachdeva
INSERT ON DUPLICATE UPDATE deadlock issuw with next-key lock

Attachment: INSert_UPDATE_DEADLOCK.txt (text/plain), 2.47 KiB.