Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
10.2(EOL), 10.3(EOL), 10.4(EOL)
Description
The following assertion could fail during InnoDB crash recovery or mariabackup --prepare if data files with unflushed changes were closed by fil_system->LRU and later reopened due to pending I/O:
10.2 bb4f4b3a1b6c9287fcef6a6d290fd228e8a181f1 |
mariabackup: /mariadb/10.2/storage/innobase/fil/fil0fil.cc:582: bool fil_node_t::read_page0(bool): Assertion `space->free_limit == 0 || space->free_limit == free_limit' failed.
|
It is possible that this has been broken ever since MariaDB 10.2.2, which incorporated the InnoDB changes from MySQL 5.7.9. The fil_space_t fields are a recent addition.
The problem is that the function fil_node_t::read_page0() is replacing the up-to-date metadata with an old version of page 0 that is being reread from the file. A more up-to-date page 0 still exists in the buffer pool, not flushed yet.
This crash was initially reported in MDEV-19346 with a nondeterministic test case, but it should be unrelated to the original topic of MDEV-19346.
In MDEV-16526, perhaps we could make it so that before files are closed, an attempt to write back any unflushed changes will be performed.
Attachments
Issue Links
- blocks
-
MDEV-19346 Assertion `recv_sys->mlog_checkpoint_lsn <= recv_sys->recovered_lsn' failed in recv_parse_log_recs during mariabackup --prepare
- Closed
- relates to
-
MDEV-16526 Overhaul the InnoDB page flushing
- Closed