Details
-
Bug
-
Status: Confirmed (View Workflow)
-
Critical
-
Resolution: Unresolved
-
10.11, 11.4, 11.8
-
Can result in hang or crash
-
Q4/2025 Server Maintenance
Description
As I understand, the assertion was added recently, so I'm filing it for the main branch. Howevever, I've also seen old ref_count assertions while trying to reproduce it, so maybe it's all the same.
main 22efc2c784e1b7199fb5804e6330168277ea7dce |
(rr) bt
|
#0 __pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:44
|
#1 __pthread_kill_internal (signo=6, threadid=<optimized out>) at ./nptl/pthread_kill.c:78
|
#2 __GI___pthread_kill (threadid=<optimized out>, signo=signo@entry=6) at ./nptl/pthread_kill.c:89
|
#3 0x000055de8fc9d27e in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
|
#4 0x000055de8fc808ff in __GI_abort () at ./stdlib/abort.c:79
|
#5 0x000055de8fc8081b in __assert_fail_base (fmt=0x55de8fe281e8 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x55de91551c15 "\"unexpected references\" == 0",
|
file=file@entry=0x55de9144eea0 "/data/MDEV-36436/main/storage/innobase/handler/ha_innodb.cc", line=line@entry=14382,
|
function=function@entry=0x55de91453f20 "virtual int ha_innobase::rename_table(const char*, const char*)") at ./assert/assert.c:96
|
#6 0x000055de8fc93517 in __assert_fail (assertion=0x55de91551c15 "\"unexpected references\" == 0", file=0x55de9144eea0 "/data/MDEV-36436/main/storage/innobase/handler/ha_innodb.cc",
|
line=14382, function=0x55de91453f20 "virtual int ha_innobase::rename_table(const char*, const char*)") at ./assert/assert.c:105
|
#7 0x000055de906a5c55 in ha_innobase::rename_table (this=<optimized out>, from=<optimized out>, to=<optimized out>) at /data/MDEV-36436/main/storage/innobase/handler/ha_innodb.cc:14382
|
#8 0x000055de90a4587e in mysql_rename_table (base=base@entry=0x55decf215c58, old_db=old_db@entry=0x72ae5f25a390, old_name=old_name@entry=0x72ae5f25a3a0,
|
new_db=new_db@entry=0x72ae5f25a390, new_name=new_name@entry=0x72ae5f258d90, id=id@entry=0x72ae5f25a430, flags=22) at /data/MDEV-36436/main/sql/sql_table.cc:5553
|
#9 0x000055de90a5c500 in mysql_alter_table (thd=thd@entry=0x232670000d58, new_db=new_db@entry=0x232670005970, new_name=new_name@entry=0x232670005dd8,
|
create_info=create_info@entry=0x72ae5f25b250, table_list=<optimized out>, table_list@entry=0x2326700167c8, recreate_info=recreate_info@entry=0x72ae5f25b0a0,
|
alter_info=<optimized out>, order_num=<optimized out>, order=<optimized out>, ignore=<optimized out>, if_exists=<optimized out>) at /data/MDEV-36436/main/sql/sql_table.cc:12051
|
#10 0x000055de90ac9801 in Sql_cmd_alter_table::execute (this=<optimized out>, thd=0x232670000d58) at /data/MDEV-36436/main/sql/sql_alter.cc:701
|
#11 0x000055de9098c3d7 in mysql_execute_command (thd=thd@entry=0x232670000d58, is_called_from_prepared_stmt=is_called_from_prepared_stmt@entry=false)
|
at /data/MDEV-36436/main/sql/sql_parse.cc:5886
|
#12 0x000055de90990a4b in mysql_parse (thd=0x232670000d58, rawbuf=<optimized out>, length=<optimized out>, parser_state=<optimized out>) at /data/MDEV-36436/main/sql/sql_parse.cc:7915
|
#13 0x000055de90992715 in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x232670000d58,
|
packet=packet@entry=0x23267000ba79 "/* WRK-1 QNO 795 */ ALTER IGNORE TABLE `advanced_db`.`t4` CHANGE IF EXISTS `col_int` col_int BOOL NULL DEFAULT NULL",
|
packet_length=packet_length@entry=116, blocking=blocking@entry=true) at /data/MDEV-36436/main/sql/sql_parse.cc:2001
|
#14 0x000055de90993f25 in do_command (thd=thd@entry=0x232670000d58, blocking=blocking@entry=true) at /data/MDEV-36436/main/sql/sql_parse.cc:1415
|
#15 0x000055de90ac31ad in do_handle_one_connection (connect=<optimized out>, put_in_cache=true) at /data/MDEV-36436/main/sql/sql_connect.cc:1415
|
#16 0x000055de90ac34bd in handle_one_connection (arg=0x55decffbb0b8) at /data/MDEV-36436/main/sql/sql_connect.cc:1327
|
#17 0x000055de8fcf4aa4 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:447
|
#18 0x000055de8fd81a34 in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:100
|
rr profile is provided.
The rr profile was generated with
c617a21063f65767417c032099c17313cd4fab6d |
perl ./run.pl --compatibility=120099 --engine=InnoDB --filter=conf/ff/restrict_dynamic_vars.ff --grammar=conf/yy/alter_table_data_types.yy --scenario=Standard --duration=300 --mysqld=--max-statement-time=8 --mysqld=--lock-wait-timeout=5 --mysqld=--innodb-lock-wait-timeout=3 --threads=2 --gendata=advanced --queries=1000000 --reporters=Backtrace --base-port=14000 --basedir=/data/bld/main-asan/ --vardir=/home/elenst/tmp/var-rqg4 --seed=1743214242 --trials=5 --rr |
Attachments
Issue Links
- relates to
-
MDEV-11342 OQGRAPH should acquire meta-data locks on "backing" tables
-
- Open
-
-
MDEV-35000 dict_table_close() breaks innodb_stats_auto_recalc
-
- Closed
-
-
MDEV-36122 Assertion failure ctx0->old_table->get_ref_count() == 1 in ha_innobase::commit_inplace_alter_table()
-
- Closed
-
-
MDEV-36493 Atomic CREATE OR REPLACE ... SELECT blocks InnoDB purge
-
- Confirmed
-