MDEV-29250 InnoDB: Failing assertion: table->get_ref_count() == 0
Reason: ====== This issue is caused by race condition between fulltext DDL and purge thread. DDL sets the signal to stop the purge thread to process the new undo log records and wait for the ongoing processed FTS table undo log records to finish. But in dict_acquire_mdl_shared(),InnoDB release all innodb table related locks before acquiring the mdl. At the same time, DDL assumes that there are no purge threads working on fts table. There is a possiblity that purge thread can skip processing the valid undo log records if it checks purge_sys.must_wait_FTS() twice in different places. Solution: ========== Add the purge_sys.must_wait_FTS() check in dict_acquire_mdl_shared() to avoid the purge thread processing undo log records. dict_open_table_on_id(): return -1 if the purge thread has to wait dict_acquire_mdl_shared(): Added 1 new parameters to indicate that purge thread invoking the function, return -1 if the purge thread has to wait.
Showing
Please register or sign in to comment