ITNEXT

ITNEXT is a platform for IT developers & software engineers to share knowledge, connect, collaborate, learn and experience next-gen technologies.

Follow publication

Member-only story

Benchmark PostgreSQL: cross between native versus Docker

Petr Jahoda
ITNEXT
Published in
5 min readJul 19, 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. This time, we will be testing PostgreSQL 13 only, on linux machine, using AWS, and the test will be using the same code as before.

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

I am expecting no significant differences, but numbers will tell us more.

Preparing the linux machine in AWS

For this specific test, t2.micro was selected: 1xCPU and 1GB RAM, eligible for free tier. After connecting into the running machine, we can check the information to see, what is running.

First step, after your cloud machine is running, is to install Docker:

  • update the machine running sudo yum update -y
  • install Docker using sudo yum install docker -y
  • enable Docker using sudo systemctl enable docker
  • start Docker using sudo systemctl start docker
  • add your user to docker group using…

Create an account to read the full story.

The author made this story available to Medium members only.
If you’re new to Medium, create a new account to read this story on us.

Or, continue in mobile web

Already have an account? Sign in

Published in ITNEXT

ITNEXT is a platform for IT developers & software engineers to share knowledge, connect, collaborate, learn and experience next-gen technologies.

Written by Petr Jahoda

Love programming, math, running and piano

Responses (5)

Write a response