My MySQL command prompt

Earlier this week we had a discussion with fellow DBAs about our mysql prompts, and at the end of the day it showed up, that a lot of us hit the same problem.

The problem is, that when you set up your mysql prompt then ‘\h’ will be resolved to ‘localhost’ when you connect locally – instead the name of your host as you expect it. It always bugs me, and once I spent a good afternoon figuring out how to workaround this.

Well, the workaround is not a big deal, because you can insert any text into your mysql prompt, and after you realise that you can do it, then it is easy: just put the hostname into your prompt with your chosen provisioning tool and that will do.

Continue reading “My MySQL command prompt”

MySQL/docker performance report update

Saturday I was in my favorite grocery store, standing in the line, browsing the net on my phone. I read Vadim Tkachenko‘s blog post about Measuring Percona Server Docker CPU/network overhead and his findings were opposite than mine – he didn’t found any measurable difference. Reading his post, he did found huge impact in networking which I didn’t check, so I was re-run my checks again, but now with paying attention to network configuration.

Continue reading “MySQL/docker performance report update”

MySQL in docker or native – performance benchmarks

Back in October I have write about possible ways of running multiple MySQL instances on the same hardware. As the months passing by, the project of splitting our database schemas into standalone instances is closing in, so I started to check the different ways.

EDIT: This post is outdated, here is the follow up.

Continue reading “MySQL in docker or native – performance benchmarks”

Streaming MySQL binary logs for backup

With MySQL, it is relatively easy to create “point in time” restores. All you need is recent(ish) backup and a bunch of saved binary logs. You can restore the backup you have, and when it is completed, you can use mysqlbinlog utility to apply your saved binary logs to the desired state of your database.

I have created a simple go application to make your life easier. You can find it on my GitHub page.

Continue reading “Streaming MySQL binary logs for backup”

Running multiple instances on the same hardware

Currently, we have one database cluster with 15 different schemas – these schemas could be either schema which contains “real” data, or just schemas with metadata.

I guess the next evolutionary step of our database stack would be to split up the database cluster vertically along these schemas. All the data schemas should be moved to standalone mysql instances and put the metadata schemas next to them. This also could be a good project for prepare to move a certain part of the database for example to a cloud provider while other parts are still kept on bare metal.

Continue reading “Running multiple instances on the same hardware”

Percona Live Europe 2015

Well, it was ended a week ago, but I had too many errands to run so I couldn’t post anything about it.

It was really great, again.This was the third time I attended (2013 London, 2015 Santa Clara) so now I have met with a lot of familiar people – it is true that MySQL has a great community. The chosen city was great, Amsterdam is one of the coolest places in Europe, the hotel was neat, and the programs were also astounding.

The conference sessions were great too, I really enjoyed, them all, and because they are running on 8 thread parallel it is not that bad that there are some recurring sessions; if you missed one in spring you can watch it on autumn.

So, everything was comfy and neat. I hope I’ll attend on the next one too …

There were a few topics where I plan to dig deeper in the next weeks

  • ProxySQL because HAProxy is a good choice, but it only speaks TCP and HTTP but not MYSQL
  • Semi-Sync replication, because getting rid of replication lag would be useful
  • XtraDB Cluster/Galera cluster, because it seems a good evolutionary step beyond our current setup
  • DB options in the cloud.