Details
-
Bug
-
Status: Closed (View Workflow)
-
Blocker
-
Resolution: Fixed
-
11.2.3, 11.3.2, 11.4.1, 11.2.4
Description
The following was found while testing a proposed fix of MDEV-34200 on 11.4:
innodb.undo_upgrade '64k' w1 [ fail ] Found warnings/errors in server log file!
|
Test ended at 2024-05-22 08:14:23
|
line
|
mariadbd: /mariadb/11/storage/innobase/mtr/mtr0mtr.cc:562: void mtr_t::commit_shrink(fil_space_t &, uint32_t): Assertion `!high_level_read_only' failed.
|
The failure is sporadic. I was able to reproduce it locally with a MemorySanitizer build. The relevant part of the server error log is the following:
2024-05-22 8:14:10 0 [Note] /dev/shm/11msan/sql/mariadbd (initiated by: root[root] @ localhost []): Normal shutdown
|
2024-05-22 8:14:10 0 [Note] InnoDB: Truncating system tablespace from 1216 to 192 pages
|
mariadbd: /mariadb/11/storage/innobase/mtr/mtr0mtr.cc:562: void mtr_t::commit_shrink(fil_space_t &, uint32_t): Assertion `!high_level_read_only' failed.
|
We should be in read-only mode because the test invokes innodb_force_recovery=5. Another reason could be innodb_read_only=ON. The fix is simple: do not invoke fsp_system_tablespace_truncate() on slow shutdown when we are in read-only mode. This condition was missed in MDEV-32452.
Attachments
Issue Links
- blocks
-
MDEV-34200 InnoDB tries to write to read-only system tablespace in buf_dblwr_t::init_or_load_pages()
- Closed
- is caused by
-
MDEV-32452 InnoDB system tablespace is not shrunk on slow shutdown
- Closed