Details
-
Bug
-
Status: Confirmed (View Workflow)
-
Major
-
Resolution: Unresolved
-
10.5, 10.6, 10.11, 11.1(EOL), 11.2, 11.4, 10.7(EOL), 10.8(EOL), 10.9(EOL), 10.10(EOL), 11.0(EOL), 11.3(EOL)
Description
Currently, opening and closing InnoDB data files is protected by fil_system.mutex. Based on MDEV-32027, opening files may incur some overhead. Scalability could be better if opening and closing file handles was protected by the something in the fil_space_t of the affected tablespace, rather than by the InnoDB-wide fil_system.mutex.
Initially I thought that we could use fil_space_t::latch, but it seems to be better to introduce a separate srw_mutex for protecting the file handles, because fil_space_t::latch can be held in operations that are allocating or freeing pages inside a tablespace. Such operations could involve page I/O, which in turn could require opening and closing data files.
Attachments
Issue Links
- relates to
-
MDEV-32027 Opening all .ibd files on InnoDB startup can be slow
- Closed
-
MDEV-33357 ALTER TABLE ... IMPORT TABLESPACE causes innodb_fatal_semaphore_wait_threshold was exceeded for dict_sys.latch.
- Open