Mariadb on Debian Wheezy

From banana_wiki
Jump to: navigation, search

MariaDB is a freedom respecting fork of MySQL, that is binary compatible and is a drop in replacement for MySQL. In theory all one has to do is “drop it in” and your off.

Here is how to replace it in Wheezy.

First let’s stop MySQL

/etc/init.d/mysql stop

Next we need to add the repos for the software, we are using OSUOSL for ours. You can select from others here

apt-get install python-software-properties
apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 0xcbcb082a1bb943db
add-apt-repository 'deb http://ftp.osuosl.org/pub/mariadb/repo/5.5/debian wheezy main'

Next we need to tell Debian to ignore the version of libmysqlclient18 in the official repos and give priority to the one from MariaDB’s.

echo -e "Package: libmysqlclient18\nPin: origin ftp.osuosl.org\nPin-Priority: 1000" > /etc/apt/preferences.d/mariadb-mysqlclient18

Now we can finally install MariaDB

apt-get update
apt-get install mariadb-server</code>

Let’s check to see if MariaDB is running/has replaced MySQL

/etc/init.d/mysql status