Open Source Databases on Big Machines: Disk Speed and innodb_io_capacity

In this blog post, I’ll look for the bottleneck that prevented the performance in my previous post from achieving better results.

The powerful machine I used in the tests in my previous post has a comparatively slow disk, and therefore I expected my tests would hit a point when I couldn’t increase performance further due to the disk speed.

Versions tested and configuration: same as in the first post of this series (check the post for specifics).

Even though I expected my tests would stop increasing in performance due to the disk speed, I did not observe high IO rates in the
iostat output. I already tested with a full data set that fits in memory. In this case, write performance only affected data flushes and log writes. But we should still see a visible decrease in speed. So I decided to try RW tests totally in memory. I created a ramdisk and put the MySQL datadir on it. Surprisingly, results on the SSD and ramdisk did not differ.

It’s interesting that the value of
innodb_io_capacity does not have any effect on this situation. Data for the graph below was taken when I ran tests on ramdisk. I wanted to see if I could control the IO activity of a disk, which is extremely fast by default, using this variable.

This totally contradicts all my past experiences with smaller machines. Percona re-purposed the machine with a faster disk (which I used before, described in this post), so I used a similar one with slower disk speed.

Again, in this case
innodb_io_capacity benchmarks with a smaller number of CPU cores showed more predictable results.

Conclusion:

Both MySQL and PostgreSQL on a machine with a large number of CPU cores hit CPU resources limits before disk speed can start affecting performance. We only tested one scenario, however. With other scenarios, the results might be different.

Related

Sveta joined Percona in 2015. Her main professional interests are problem solving, working with tricky issues, bugs, finding patterns that can solve typical issues quicker and teaching others how to deal with MySQL issues, bugs and gotchas effectively. Before joining Percona Sveta worked as a Support Engineer in the MySQL Bugs Analysis Support Group in MySQL AB-Sun-Oracle.

She is the author of the book “MySQL Troubleshooting” and JSON UDF functions for MySQL.

10 Comments

Sveta, this is a very interesting observation indeed. However, I was hoping that you would have kept using the same filesystem in both scenarios, any reasons for not keeping it the same? If they were actually different, do we risk this comparison becoming a filesystem benchmark?

Do you mean Percona and Freematiq machines? I did not try to compare them. But Percona machines are more like those which I see when work on Support issues and they demonstrate behavior I used to. So I use them as a baseline and to check if I am not doing something wrong with the test itself.

This is certainly not filesystem benchmark, because workload is not disk-bound by its nature. Still I expected I would hit disk performance issues on Freematiq machine at some point and I did not.

Yes, but I am not comparing filesystems or even Freematiq and Percona machine. I used smaller machine to show behavior which I expect based on my Support experience. See more detailed reply to the previous comment.