Bug #115328 | Poor write performance due to new default value of innodb_doublewrite_pages | ||
---|---|---|---|
Submitted: | 14 Jun 2024 2:13 | Modified: | 18 Jun 2024 7:00 |
Reporter: | SeWoong Jeon | Email Updates: | |
Status: | Analyzing | Impact on me: | |
Category: | MySQL Server: InnoDB storage engine | Severity: | S5 (Performance) |
Version: | 8.4.0 | OS: | Red Hat (Rocky Linux 8.8) |
Assigned to: | MySQL Verification Team | CPU Architecture: | x86 |
Tags: | doublewrite, innodb |
[14 Jun 2024 2:13]
SeWoong Jeon
[14 Jun 2024 14:47]
Dimitri KRAVTCHUK
Could you try, please, to replay the same tests on your system, but just using most of 8.4 defaults like just the following : innodb_buffer_pool_size = 64G innodb_dedicated_server = ON (BP size remains 64GB to respect your IO-bound test conditions)
[18 Jun 2024 6:04]
SeWoong Jeon
Thanks for the advice!! As you suggested, I removed all innodb related settings from my.cnf and left only the "innodb_buffer_pool_size = 64G & innodb_dedicated_server = ON". Although throughput has increased compared to the last test, changes in redo log capacity and background thread settings seem to have had an effect. So, I compared the results of a test run with only the "dedicated_server = on" setting and the test results with the "innodb_doublewrite_pages = 16" setting added. The gap has narrowed since the previous test, but write performance was still good when innodb_doublewrite_pages = 16 was set. I took the test 3 times and the results were similar. === Previous Test Result (dedicated_server = off) === sysbench 16thd innodb_doublewrite_pages = 128 - queries: 22852.44 per sec. / avg latency: 4.20ms innodb_doublewrite_pages = 16 - queries: 24259.34 per sec. / avg latency: 3.96ms sysbench 64thd innodb_doublewrite_pages = 128 - queries: 35491.13 per sec. / avg latency: 10.82ms innodb_doublewrite_pages = 16 - queries: 40553.01 per sec. / avg latency: 9.47ms === New Test Result (dedicated_server = on) === sysbench 16thd dedicated_server = on - queries: 46993.39 per sec. / avg latency: 2.04ms dedicated_server = on + innodb_doublewrite_pages = 16 - queries: 47976.09 per sec. / avg latency: 2.00ms sysbench 64thd dedicated_server = on - queries: 64287.17 per sec. / avg latency: 5.97ms dedicated_server = on + innodb_doublewrite_pages = 16 - queries: 68369.34 per sec. / avg latency: 5.61ms
[20 Jun 2024 18:09]
Dimitri KRAVTCHUK
I'd rather expect to see you excited to obtain mostly *twice* better performance on your test workload with the new 8.4 defaults, but not ;-)) Now, regarding DBLWR tuning and any other : - mind that defaults are not supposed to be the best choice for any workload ! - the main point is to make them to be "good enough" in the most cases - additionally, it's not only about performance, but also about overall data safety as the first priority ! - so, you can always fine a better tuning for a given workload - but this will not mean it'll be also good in another workload, or on another system, etc.