Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
10.0.11, 10.1.0, 10.2.0, 5.5.55, 10.3.0, 10.4.0
Description
When InnoDB is invoking posix_fallocate() to extend data files, it is missing a call to fsync() to update the file system metadata. If file system recovery is needed, the file size could be incorrect.
Furthermore, when the setting innodb_flush_method=O_DIRECT_NO_FSYNC that was introduced in MariaDB 10.0.11 (and MySQL 5.6) is enabled, InnoDB would stop calling fsync() after extending files.
This report is motivated by a MySQL 5.7.25 change Bug#27309336 Backport to 5.7 that restores the fsync() call. We will fix the bug differently; it does not seem to be a good idea to hold the already contentious fil_system->mutex while executing a system call.
Attachments
Issue Links
- blocks
-
MDEV-18338 Merge new release of InnoDB 5.7.25 to 10.2
- Closed
- relates to
-
MDEV-4338 Support FusionIO/directFS atomic writes.
- Closed
-
MDEV-11520 Extending an InnoDB data file unnecessarily allocates a large memory buffer on Windows
- Closed