Wrong usage of mutex 'share->bitmap.bitmap_lock' and 'share->intern_lock' on Aria table update with low aria-pagecache-buffer-size
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
MariaDB |
Won't Fix
|
Undecided
|
Michael Widenius |
Bug Description
The attached test case causes error messages in the server error log
safe_mutex: Found wrong usage of mutex 'share-
Mutex currently locked (in reverse order):
share->intern_lock ma_locking.c line 425
share->
or, if it's run with debug-assert-
mysqld: thr_mutex.c:841: print_deadlock_
#8 0xb7583014 in __assert_fail () from /lib/libc.so.6
#9 0x0869ab4b in print_deadlock_
#10 0x08699975 in safe_mutex_lock (mp=0x93062ac, my_flags=0, file=0x87e6750 "ma_locking.c", line=425) at thr_mutex.c:366
#11 0x08564a06 in _ma_mark_
#12 0x08553eea in maria_flush_
#13 0x08528e2b in pagecache_fwrite (pagecache=
at ma_pagecache.c:658
#14 0x0852c364 in find_block (pagecache=
page_
#15 0x08531931 in pagecache_
lock=
size=8192) at ma_pagecache.c:4092
#16 0x084fbd05 in write_changed_
#17 0x084fc67f in _ma_bitmap_flush (share=0x9305cf0) at ma_bitmap.c:418
#18 0x084f6632 in _ma_scan_
#19 0x08517a46 in maria_scan_init (info=0x930f9e8) at ma_scan.c:29
#20 0x084cdb9d in ha_maria::rnd_init (this=0x9304cd8, scan=true) at ha_maria.cc:2252
#21 0x08184bde in handler:
#22 0x0837ef69 in handler:
#23 0x083761f5 in init_read_record (info=0xb697e6d4, thd=0x920e5d8, table=0x92f49f0, select=0x0, use_record_cache=0, print_error=true, disable_
at records.cc:261
#24 0x0830a348 in mysql_update (thd=0x920e5d8, table_list=
handle_
#25 0x0826469e in mysql_execute_
#26 0x0826d33b in mysql_parse (thd=0x920e5d8, rawbuf=0x927ad88 "UPDATE t16 SET id_board = 3", length=27, found_semicolon
#27 0x0825fe9c in dispatch_command (command=COM_QUERY, thd=0x920e5d8, packet=0x9265821 "UPDATE t16 SET id_board = 3", packet_length=27) at sql_parse.cc:1232
#28 0x0825f35d in do_command (thd=0x920e5d8) at sql_parse.cc:919
#29 0x0825d64c in handle_
#30 0xb7810b25 in start_thread () from /lib/libpthread
Reproducible on 5.2, 5.3, 5.5.
To reproduce, run the attached MTR test as
perl ./mtr --mysqld=
Changed in maria: | |
assignee: | nobody → Michael Widenius (monty) |
This is fixed in 5.3 (verified by Elena)
As 5.3 is now GA and this issue is not likely to happen, we will not backport the fix .2 for now.
If a lot of users or a a paying customer wants to have this fixed, lets backport the fix.
The fix is part in Revno: 3442.1.1 and 3442.1.2