MariaDB Supported?

Does Piwik support MariaDB as a MySQL replacement?

I have moved all of our sites over to MariaDB and the only thing left is Piwik. Its basically a binary replacement for MySQL, but it is not compatible with everything out there yet[1]. Would be great if you guys could support MariaDB as well, especially for the following reasons

The biggest issue with MySQL is that Oracle is pushing for this to be closed source more and more. They no longer publish regression tests[2], security advisories and are now even hiding bug reports which are no longer included in even the release notes[3]. Most of the time their repo is behind what is being released in their tarballs[4].

MariaDB is truly opensource, just like Piwik and I think offering a true OpenSource DB solution would give Piwik an even bigger edge.

[1] https://kb.askmonty.org/en/mariadb-vs-mysql-compatibility
[2] http://blog.mariadb.org/disappearing-test-cases/
[3] http://ronaldbradford.com/blog/when-is-a-crashing-mysql-bug-not-a-bug-2012-08-15/
[4] http://www.mysqlperformanceblog.com/2012/08/16/where-to-get-a-bzr-tree-of-the-latest-mysql-releases/

Piwik works with MariaDb without any problems.
There is no special need to “support” it, as its just a mysql server under the hood.

Actually MariaDB does not work out of the box for everything that works with MySQL, hence the link I posted which states all the things that will be incompatible. That is why I wanted to see if it has been done and is actually a “supported” DB by Piwik to use.

There were modifications I had to do, to some but not all of the DB’s I have already moved over to MariaDB, which I am too understand is something that does happen.

So I guess I will change the question, who is running MariaDB and what modifications did you have to make if any?

Well, then let me rephrase my answer: I’m running quite some piwik instances on mariadb (currently 5.5.27) for years now and there were NO changes needed at all.

OK thank you. Might be something worth putting into your Doc’s someplace. Just so people can get the info from the Documentation available.

That is really interesting!! Thomas, you should tell us more about this as it’s very exciting, and I didn’t know the clear change of direction in mysql community spirit…

@vwyoda or Thomas, if you’d like to write a FAQ about it, that would be great, or let me know what info to write to make it relevant/interesting!

Also what are the performance benefits between mariadb and mysql for piwik?

I am going to clone my server tonight and throw it up to test the switch over. But if its like Thomas states, it should litterally be as simple as adding the MariaDB repo if you are a Debian based system and then install it through apt, which will automatically remove mysql. It will leave everything in place from the previously installed MySQL install and just work hopefully. I will report back if it is just that simple.

But yes Oracle is ruining MySQL as we know it, it may still be a great DB but its gone away from one of its greatest attributes, OpenSource.

Depending on who you talk to or comparison you believe, MariaDB is said to be faster than MySQL but does not have as good of throughput as Percona. So far I am very happy with the switch I have been able to scale down 2 of the DB servers we have running.

For me the move is not to gain some performance gain, but just to keep with OpenSource software I believe in the route they want to follow. To me some of the things MySQL has stopped giving out as noted in my first post were the deal breakers for me. Also MariaDB offers XtraDB which is a “an enhanced and extended version of the InnoDB storage engine” that I want to give a whirl.

p.s. Nice change to the forums!

Just to update this for anyone else wanting to do the same thing.

For me it was as simple as installing mariadb. Running the install automatically removes mysql leaving everything else behind, such as your DBs and config file. Then bam mariadb worked, nothing else required.

One day of running and no issues noticed.

Of course remember to make a backup just incase.

If anyone else has different results would be great to put them here.

This worked successfully for me on Arch Linux and Ubunu installs of piwik.

Nice! very interesting.

Let me know if you see performance differences between MariaDB and mysql, if any.

Well it is too early to say definitively that there is a major performance improvement. But I do see this server is no longer using as much memory and CPU. The only thing on the server is a Piwik install, that tracks 19 sites. With a daily total through all sites at an average of 1.2 mil. It use to consume on average of 7GB of memory now its averaging at about 4.5GB or a little higher. CPU usage has also dropped.

But so far I would say if there is anyone else fed up with Oracle and what MySQL has become, try our MariaDB, you might be very happy with your results. I am sure results will vary but at least there is a solid alternative that keeps with the sense of true OpenSource.

Hi guys,

we just wrote a blog post about MariaDB on the blog: Piwik analytics database: migrating from MySQL to MariaDB - Analytics Platform - Matomo