This patch is conjugation of Yasufumi's IO patches (control_io-threads.patch, control_flush_and_merge_and_read.patch, adaptive_flush.patch).

The patch adds next configuration parameters:

(The following parameters are implemented after v1.1)


The patch adds next information into SHOW INNODB STATUS to confirm the checkpointing activity:

  1. max checkpoint age
  2. current age of oldest page modification which have not been flushed to disk yet.
  3. current age of the last checkpoint
...
---
LOG
---
Log sequence number 0 1059494372
Log flushed up to   0 1059494372
Last checkpoint at  0 1055251010
Max checkpoint age  162361775
Modified age        4092465
Checkpoint age      4243362
0 pending log writes, 0 pending chkp writes
...

(*) adaptive checkpointing

InnoDB flushes dirty blocks of buffer pool constantly. And normally, the checkpoint is done at oldest page modification at the time passively (This is called ”fuzzy checkpointing”). When the checkpoint age grows near to the max checkpoint age (determined by total of transaction log files' length), InnoDB tries to keep the checkpoint age away from the max by ad-hoc flushing many dirty blocks. But if there are many update per second and many blocks which are almost same modification age, huge number of flushing and stallings may be caused.

adaptive checkpointing reinforces the constant flushing activity along the rate of [modified age / max checkpoint age]. It might avoid or soften the impact of the such huge flushing or stallings.

Discussion

Sheeri Cabral, 2009/12/09 10:34

The “default” value for innodb_ibuf_max_size is not the same as the size acutally used by the database:

$ grep ibuf /etc/my.cnf $ grep buffer_pool /etc/my.cnf innodb_buffer_pool_size = 4G $ mysqld –verbose –help | grep innodb_ibuf_max_size

  1. -innodb_ibuf_max_size=#

innodb_ibuf_max_size 9223372036854775807 $ mysql -u [user] -p -e “show variables like 'innodb_ibuf_max_size'” Enter password: +———————-+————+

Variable_name Value

+———————-+————+

innodb_ibuf_max_size 2147483648

+———————-+————+

So with no explicit setting of innodb_ibuf_max_size, the default is huge, but is actually changed to something more reasonable (2G in this case, which is 1/2 the buffer pool of 4G) when mysqld actually starts.

I wasn't sure where to file this bug, because there doesn't seem to be a place to file bugs for the percona-highperf versions, only the xtradb versions. :(

Some more information: mysqld –version mysqld Ver 5.0.86-percona-highperf-b19-log for unknown-linux-gnu on x86_64 (MySQL Percona High Performance Edition, Revision 60 (GPL))

$ uname -a Linux [machine] 2.6.18-xenU-ec2-v1.0 #2 SMP Mon Feb 18 14:28:43 UTC 2008 x86_64 x86_64 x86_64 GNU/Linux $ cat /etc/issue CentOS release 5.0 (Final) Kernel \r on an \m

Enter your comment (wiki syntax is allowed):
USMDQ
 
patches/innodb_io_patches.txt · Last modified: 2009/05/06 17:02 by kinoshita
 
Except where otherwise noted, content on this wiki is licensed under the following license:GNU Free Documentation License 1.2
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki