For all practical purposes, you can view MariaDB as an upgrade of MySQL:

  • If you are using Windows, see also Upgrading MariaDB on Windows.
  • For upgrading from very old MySQL versions, see Upgrading to MariaDB from MySQL 5.0 (or older version).
  • Within the same base version (for example 5.1) you can just uninstall MySQL and install MariaDB and you are good to go. There is no need to dump and restore databases. As with any upgrade, we recommend making a backup of your data beforehand.
  • You should run mysql_upgrade (just as you would with MySQL) to finish the upgrade. This is needed to ensure that your mysql privilege and event tables are updated with the new fields MariaDB uses. Note that if you use a MariaDB package, mysql_upgrade is usually run automatically.
    • After running mysql_upgrade you should restart MariaDB so that the new changes takes effect.
  • All your old clients and connectors (PHP, Perl, Python, Java, etc.) will work unchanged (no need to recompile). This works because MariaDB and MySQL use the same client protocol and the client libraries are binary compatible. You can also use your old MySQL connector packages with MariaDB if you want.

Upgrading my.cnf

All the options in your original MySQL my.cnf file should work fine for MariaDB.

However as MariaDB has more features than MySQL, there is a few things that you should consider changing in your my.cnf file.

  • MariaDB uses by default the Aria storage engine for internal temporary files, instead of MyISAM. If you have a lot of temporary files, you should add and set aria-pagecache-buffer-size to the same value as you have for key-buffer-size.
  • If you don't use MyISAM tables, you can set key-buffer-size to a very low value, like 64K.

Other things to think about.

  • MariaDB has LGPL versions of the C connector and Java. If you are shipping an application that supports MariaDB or MySQL you should consider using these!
  • You should consider trying out the TokuDB storage engine or some of the other new storage engines that MariaDB provides.

See Also


Comments loading...