Benchmark MariaDB: cross between native versus Docker

Petr Jahoda
ITNEXT
Published in
3 min readJul 29, 2021

--

Few months ago, I did two benchmarks. The first one tested three database engines and the second one only PostgreSQL.

You can find those benchmarks in those two links below. Both articles are written by Petr Jahoda.

Because there were some ideas about this benchmark, I decided to make another one on PostgreSQL only. You can find that article in the link below.

While reading through responses to this latest PostgreSQL-only article (and on Reddit), there were numerous request to do the same with MySQL based database. Because previous benchmark showed that MariaDB performs a little bit better, MariaDB was used in this test.

We will have four tests:

  • database running natively, program running natively
  • database running in Docker, program running natively
  • database running in Docker, program running in Docker
  • database running natively, program running in Docker

We will use the same technique, that is described in the article above, so no need to add information about settings AWS and databases here and we can jump into the results.

Initial Conditions

  1. AWS t2.micro linux was used
  2. All data (Docker database and native database) are on the same partition
  3. Default MariaDB settings were used for both
  4. The same version 10.6.x…

--

--