[MDEV-14082] Enforcing innodb_open_files leads to fil_system->mutex problem Created: 2017-10-17  Updated: 2017-10-17  Resolved: 2017-10-17

Status: Closed
Project: MariaDB Server
Component/s: Storage Engine - InnoDB
Affects Version/s: 10.2.4, 10.3.0
Fix Version/s: 10.2.10, 10.3.3

Type: Bug Priority: Major
Reporter: Marko Mäkelä Assignee: Marko Mäkelä
Resolution: Fixed Votes: 0
Labels: crash

Issue Links:
Relates
relates to MDEV-11556 InnoDB redo log apply fails to adjust... Closed
relates to MDEV-13051 MySQL#86607 InnoDB crash after failed... Closed

 Description   

This was accidentally found by merging MDEV-13051 test to 10.2.
When InnoDB is trying to close data files to obey the innodb_open_files limit, it will release fil_system->mutex and fail to reacquire it. In a debug build, this will lead to a debug assertion failure.

mysqld: /mariadb/server/storage/innobase/fil/fil0fil.cc:823: bool fil_try_to_close_file_in_LRU(bool): Assertion `(&fil_system->mutex)->is_owned()' failed.

In a non-debug build, it could lead to a hang or crash (I did not test).

This was broken in a merge of 10.1 to 10.2 by me, already in MariaDB 10.2.4. The 10.1 code (changed by MDEV-11556) appears to be OK.


Generated at Thu Feb 08 08:10:47 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.