lamp-install-script icon indicating copy to clipboard operation
lamp-install-script copied to clipboard

mariadb vs mysql

Open tomas-pecserke opened this issue 12 years ago • 11 comments

Even since i suggested replacing mysql with mariadb, I've been trying to do so unsuccessfully. Finally today I've found the problem, why we couldn't install mariadb-5.5 on our ubuntu machines:

Few days ago new version of mysql 5.5.29 was released and mariadb (currently in version 5.5.28) depends on few packages from old release, which has been removed from repository. From what I can tell, all both Ubuntu and Debian repositories now contain the new mysql version. Mariadb 5.5.29 is supposed to be released any day now, so all we can do is to stay put for now.

However I was able to install mariadb 10.0 alpha, but since it's still in development, I don't consider using it in this lamp. Why I'm mentioning it, is 'cause I believe it means, we can use precise repository with quantal too.

tomas-pecserke avatar Jan 27 '13 15:01 tomas-pecserke

Great news Tom. We'll see what happens when new MariaDB version will be released.

Anyway... we should look for a solution for this problem, because it might occur again in future, when new version of MySQL will be released and MariaDB will be outdated again.

mhlavac avatar Jan 27 '13 23:01 mhlavac

Update on MariaDB 5.5.29: The word is the release is due to tomorrow.

As for solution to the incompatible version problem: The problem is, that MariaDB client library depends on an exact version of MySQL client library (no problem there, it makes sense, since it's supposed to be a drop-in) and MySQL client library got superseded by the one from new version in the official Ubuntu repository. There is not really much we can do about that. We could encourage the developers of MariaDB to sync their release cycle with MySQL's (if there is such a thing for MySQL), but there will always be delay due to need to determine changes in MySQL release and react to them accordingly. Only permanent solution is to maintain a PPA with all the dependencies. Since there would be no code added on our side, it would need only to determine the dependencies and copy according packages from other repositories. No building required. Still maintaining a repository takes a lot of time. Since MariaDB must copy MySQL release cycle, it would be required at least every 6 months (GA release cycle).

tomas-pecserke avatar Jan 28 '13 23:01 tomas-pecserke

MariaDB 5.5.29 have been released yesterday evening. There is finally quantal repository available, too.

I'm however still not sure, how we can avoid future problems with dependencies. Originally I thought I was due to missing package in repository. As it turns out, it wasn't - the needed package was available in mariadb repository, but it was "superseded" by newer version in official one, so apt wouldn't install it.

I was however able to install it via aptitude in interactive problem solution mode (I couldn't automatize the process). Maybe there is some option how to force installation of superseded packages if available.

Long story short - I'm not convinced, this situation won't reoccur. Maybe we can maintain two branches - one with MariaDB, one with MySQL.

tomas-pecserke avatar Jan 31 '13 15:01 tomas-pecserke

The problem would not occur if you wouldn't install MySQL first. I think that if you install MariaDB first there won't be a newer version and everything will work as expected.

MariaDB use would render MySQL obsolete and we could avoid installing it in the first place thus avoiding this problem in future.

mhlavac avatar Jan 31 '13 17:01 mhlavac

Not entirely - MariaDB depends on MySQL package libmysqlclient18. That was source of problem. I was unable install libmysqlclient18-5.5.28 (it's included in MariaDB repo) because it was superseded by libmysqlclient18-5.5.29 in official repo. Once you've successfully installed MariaDB, everything is fine. But if such version inconsistency occur again, you won't be able to install (new install - not update) MariaDB - dependency couldn't be met.

tomas-pecserke avatar Jan 31 '13 17:01 tomas-pecserke

So today I've came accross bug report for this issue -the problem is exactly as I described it above. https://mariadb.atlassian.net/browse/MDEV-3882

Since it's still not fixed, I'm against merging mariaDB usage into master branch.

tomas-pecserke avatar Feb 04 '13 15:02 tomas-pecserke

You can open PR for maria-db branch for users who would like to use it.

mhlavac avatar Feb 08 '13 02:02 mhlavac

That's the thing - open PR to merge it where?

tomas-pecserke avatar Feb 08 '13 09:02 tomas-pecserke

A special branch maria-db was created where you can place your changes. They might be useful in future.

mhlavac avatar Feb 15 '13 01:02 mhlavac

Installing MariaDB over existing MySQL (or even only some of it's libraries) is problematic. If you are installing lamp on machine with some desktop environment, it's highly probable, you have installed some applications, which depends (on some level) on MySQL, thus you have installed at least some client libraries of MySQL. Those libraries are the ones causing problems.

Unless we can solve this issue, I recommend against MariaDB integration into lamp.

tomas-pecserke avatar Feb 15 '13 08:02 tomas-pecserke

Great news: the guys from MariaDB Foundation fixed installing MariaDB over existing MySQL instance. I've tested it against Official Ubuntu Daily Cloud Release 12.10, Kubuntu 12.10, and Ubuntu 12.10 (Desktop).

However installation MySQL over MariaDB fails.

tomas-pecserke avatar Feb 17 '13 11:02 tomas-pecserke