This has results for IO-bound sysbench with MyRocks in FB MySQL 5.6.35 and 8.0.17. The test is similar to what I used for in-memory sysbench except the table has 400M rows instead of 10M and the test table is much larger than memory. The goal is to understand how performance and efficiency change from MySQL 5.6 to 8.0. I also have posts for InnoDB and Postgres.
Summary:
- While it varies, throughput for SELECT is frequently ~10% less in 8.0.17 vs 5.6.35
- Throughput for insert and update is 20% to 30% less in 8.0.17 vs 5.6.35
- CPU overhead is the reason for regressions, as it was for in-memory sysbench with MyRocks. It is more of an issue for insert and update because they are CPU-bound while the read-only tests do more read IO per query and are less CPU-bound.
Overview
I use my sysbench fork. I have yet to change the code but added Lua scripts for new tests. Tests are run in a sequence (prepare, pause to let write back & compaction catch up, read-only, write-heavy, pause again, read-only, delete, insert) via all_small.sh which calls another helper script, run.sh, to run tests and collect HW metrics.
The tests use 1 table with 400M rows and each test is run for 300 seconds for 1, 2 and 3 threads. The test servers have 4 CPU cores with HT disabled, 16G of RAM and NVMe SSD. The test table is much larger than RAM and I call this an IO-bound setup.
Tests used FB MySQL 5.6.35 at git hash 4911e0 and 8.0.17 at git hash cf9dbc. These were latest as of early December 2020. The servers use Ubuntu 20.04 and XFS.
Load:
- For the first 4 tests that do point queries
- QPS ratios are 0.97, 0.86, 0.92, 1.00 (here to here)
- CPU/query ratios are 1.10, 1.40, 1.23, 1.14 (here to here)
- The next 3 tests have range scans from oltp_read_write.lua with ranges of size 10, 100 & 10,000
- The next 2 tests do point queries via in-lists that are covering and not covering for the PK index
- The next 2 tests are similar to the previous but use the secondary index
- QPS ratios are 0.74, 0.98 (here to here)
- CPU/query ratios are 1.30, 1.11 (here to here)
- IO read KB/query ratios are 1.72, 1.07
- The next 2 tests do range queries that are covering and not covering for the PK index
- The next 2 tests are similar to the previous but use the secondary index
- For the next 5 tests that are update-only
- QPS ratios are 0.92, 0.86, 0.85, 0.80, 0.75 (here to here)
- CPU/query ratios are 1.21, 1.24, 1.22, 1.21, 1.36 (here to here)
- The next test is write-only that has the writes from oltp_read_write.lua
- The next 2 tests are the traditional sysbench tests with ranges of size 10 & 100
- The next 3 tests have range scans from oltp_read_write.lua with ranges of size 10, 100 & 10,000
- QPS ratios are 0.88, 0.94, 1.05 (here to here)
- CPU/transaction ratios are 1.20, 1.13, 0.98 (here to here)
- The next 5 tests do point queries
- QPS ratios are 0.85, 0.86, 0.90, 1.00, 0.84 (here to here)
- CPU/query ratios are 1.26, 1.42, 1.28, 1.24, 1.22 (here to here)
- The next 2 tests do point queries via in-lists that are covering and not covering for the PK index
- The next 2 tests are similar to the previous test but use the secondary index
- The next 2 tests do range queries that are covering and not covering for the PK index
- The next 2 tests are similar to the previous but use the secondary index
- The next test does a single-threaded full scan of the test table with a filter so that the result set is empty.
No comments:
Post a Comment