Separate DB connections for read and write #26909

schnidrig opened this Issue Jan 9, 2017 · 3 comments


None yet

3 participants



Mariadb Galera cluster.
Maxscale: read/write spliter

ownCloud version:



We at SWITCH and also some other NRENs noticed, that when using a galera
cluster, one also has to use an sql-proxy doing a read / write split.
Otherwise the db performance gets very, very bad due to some locking problems.

At SWITCH we use maxscale 1.3 for this. Unfortunately maxscale with
the read/write splitter is a terrible CPU hog.

But why should we operator have to retrofit OC with that feature?
Wouldn't it be much more efficient, if the code did use two connections.
One for write and a second one for read only db queries?

Then we could simply load balance the reads without having to inspect them.
This would save a awful lot of CPU cycles and as side effect also make OC a bit greener ;-)

timm2k commented Jan 10, 2017

I totally agree. We're using MaxScale 1.4. The CPU waste might be the same. MaxScale 2.0 might be better than 1.x but it comes with a new licensing.

My next step is to have a look at Percona does also prefer ProxySQL instead of MaxScale.


Are there other software using the same approach ? (just out of curiosity)

@DeepDiver1975 @butonic @PhilippSchaffrath


A mysql expert recently told me, that proxysql is not compatible with mariadb. I did not verify this statement tough.

There is a fork of maxscale:
Didn't take a closer look at it yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment