innodb_page_cleaners是MySQL中的刷脏线程个数,它的值等于innodb_buffer_pool_instances的值,如果innodb_page_cleaners的值大于innodb_buffer_pool_instances的值,那么自动的将innodb_page_cleaners调整为与innodb_buffer_pool_instances的值相同,其他情况不做调整。
默认值都是1,如下图:
[test]> select @@innodb_page_cleaners;
+------------------------+
| @@innodb_page_cleaners |
+------------------------+
| 1 |
+------------------------+
[test]> select @@innodb_buffer_pool_instances;
+--------------------------------+
| @@innodb_buffer_pool_instances |
+--------------------------------+
| 1 |
+--------------------------------+
innodb_page_cleaners是由一个协调线程+一个或多个task线程组成的。如果innodb_page_cleaners=1,那么它本身就是协调线程,又是工作线程。
innodb_buffer_pool_instances的值默认是1。innodb_buffer_pool_instances指的是将innodb buffer pool划分为多少个区域,区域的数量就是innodb_buffer_pool_instances的值。目的是为了便于管理减少锁的粒度,提高并发性。
如有错误,联系本人请发邮件:zgaoq@163.com