[MDEV-27295] MariaDB 10.5 does not do idle checkpoint (regression). Marked as fixed on 10.5.13 but it is not Created: 2021-12-17  Updated: 2023-11-05  Resolved: 2022-06-29

Status: Closed
Project: MariaDB Server
Component/s: Documentation, Storage Engine - InnoDB
Affects Version/s: 10.5.13
Fix Version/s: N/A

Type: Bug Priority: Major
Reporter: carlos tutte Assignee: Ian Gilfillan
Resolution: Fixed Votes: 0
Labels: None

Issue Links:
Relates
relates to MDEV-23855 InnoDB log checkpointing causes regre... Closed
relates to MDEV-24537 innodb_max_dirty_pages_pct_lwm=0 lost... Closed
relates to MDEV-24949 Enabling idle flushing (possible regr... Closed
relates to MDEV-26860 MariaDB 10.5 does not do idle checkpo... Closed

 Description   

Hi!

I upgraded to 10.5.13 to fix MDEV-26860 but it is still not fixed.

To reproduce, start a server with the defaults and check "show engine innodb status;" i.e get the following outputs:

Log sequence number 1851090
Log flushed up to 1851090
Pages flushed up to 1851090
Last checkpoint at 1851078

Then do some inserts on any table and check SEIS again:

Log sequence number 1852662
Log flushed up to 1852662
Pages flushed up to 1851090
Last checkpoint at 1851078

it can be seen that checkpoint is yet not moving forward. If monitoring with PMM, the graphs looks like a "saw tool" like on the bug report from MDEV-26860



 Comments   
Comment by Krunal Bauskar [ 2021-12-20 ]

@Carlos,

Idle flushing is enabled only if early flushing behavior is enabled (innodb_max_dirty_pages_pct_lwm != 0).
[Default innodb_max_dirty_pages_pct_lwm == 0 so the issue].

Documentation could be updated to make a note of this.

Comment by Marko Mäkelä [ 2022-01-24 ]

ctutte, did you test krunalbauskar’s suggestion?

Note: In the MariaDB Server 10.5.7 and 10.5.8 releases, the parameter value innodb_max_dirty_pages_pct_lwm=0 (which is the default) meant that the page cleaner thread would always run in the background, as long as dirty pages exist in the buffer pool.

In MDEV-24537, the original meaning of the default value was restored: it means that there will be no separate background flushing, and nothing will be written out as long as:

  • the share of dirty pages will not exceed innodb_max_dirty_pages_pct
  • the last checkpoint age (LSN difference since the latest checkpoint) does not exceed innodb_log_file_size (minus some safety margin)
  • we are not running out of space in the buffer pool, which could trigger eviction flushing

If you want background flushing to be as eager as it was in 10.5.7 and 10.5.8, I believe that the following should come close:

SET GLOBAL innodb_max_dirty_pages_pct_lwm=0.001;

Comment by Ian Gilfillan [ 2022-06-29 ]

Documentation updated at https://mariadb.com/kb/en/innodb-page-flushing/

Generated at Thu Feb 08 09:51:50 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.