Comments - Upgrading from MySQL to MariaDB

12 years, 4 months ago Jean Weisbuch

Don't forget to verify that you dont have InnoDB Plugin configured (if its the case, you just have to comment the "plugin_load = innodb[...]" and "ignore_builtin_innodb lines" in your my.cnf before launching the procedure).

When if will install the mariadb-server packages, it will ask you for the root password for the databases, you can leave that blank (just press enter) and it will keep your existing password.

MySQL 5.1 remplaced by MariaDB 5.5 on a Debian Squeeze 64bit :

root@v1421:~# gpg --keyserver keys.gnupg.net --recv-keys CBCB082A1BB943DB
gpg: requesting key 1BB943DB from hkp server keys.gnupg.net
gpg: key 1BB943DB: "Daniel Bartholomew (Monty Program signing key) <[email protected]>" not changed
gpg: Total number processed: 1
gpg:              unchanged: 0
root@v1421:~# gpg -a --export CBCB082A1BB943DB | apt-key add -
OK
root@v1421:~# echo "deb http://mirror2.hs-esslingen.de/mariadb/repo/5.5/debian squeeze main" >> /etc/apt/sources.list
root@v1421:~# apt-get update && apt-get install mariadb-client mariadb-server mariadb-client-5.5 mariadb-server-5.5 mariadb-server-core-5.5 mariadb-client-core-5.5
  [apt-get update output]
The following packages were automatically installed and are no longer required:
  libwrap0 tcpd
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  libaio1 libmariadbclient18 libmysqlclient18 mariadb-common
Suggested packages:
  tinyca mariadb-test
The following packages will be REMOVED:
  mysql-client-5.1 mysql-server mysql-server-5.1 mysql-server-core-5.1
The following NEW packages will be installed:
  libaio1 libmariadbclient18 libmysqlclient18 mariadb-client mariadb-client-5.5 mariadb-client-core-5.5 mariadb-common mariadb-server mariadb-server-5.5 mariadb-server-core-5.5
0 upgraded, 10 newly installed, 4 to remove and 0 not upgraded.
Need to get 30.6 MB of archives.
After this operation, 54.7 MB of additional disk space will be used.
Do you want to continue [Y/n]? 
Get:1 http://ftp.fr.debian.org/debian/ squeeze/main libaio1 amd64 0.3.107-7 [7,928 B]
Get:2 http://mirror2.hs-esslingen.de/mariadb/repo/5.5/debian/ squeeze/main mariadb-common all 5.5.25-mariadb1~squeeze [3,262 B]
Get:3 http://mirror2.hs-esslingen.de/mariadb/repo/5.5/debian/ squeeze/main libmysqlclient18 amd64 5.5.25-mariadb1~squeeze [2,932 B]
Get:4 http://mirror2.hs-esslingen.de/mariadb/repo/5.5/debian/ squeeze/main libmariadbclient18 amd64 5.5.25-mariadb1~squeeze [812 kB]
Get:5 http://mirror2.hs-esslingen.de/mariadb/repo/5.5/debian/ squeeze/main mariadb-client-core-5.5 amd64 5.5.25-mariadb1~squeeze [1,802 kB]
Get:6 http://mirror2.hs-esslingen.de/mariadb/repo/5.5/debian/ squeeze/main mariadb-client-5.5 amd64 5.5.25-mariadb1~squeeze [5,070 kB]
Get:7 http://mirror2.hs-esslingen.de/mariadb/repo/5.5/debian/ squeeze/main mariadb-server-core-5.5 amd64 5.5.25-mariadb1~squeeze [5,180 kB]
Get:8 http://mirror2.hs-esslingen.de/mariadb/repo/5.5/debian/ squeeze/main mariadb-server-5.5 amd64 5.5.25-mariadb1~squeeze [17.7 MB]
Get:9 http://mirror2.hs-esslingen.de/mariadb/repo/5.5/debian/ squeeze/main mariadb-client all 5.5.25-mariadb1~squeeze [2,832 B]                                                                        
Get:10 http://mirror2.hs-esslingen.de/mariadb/repo/5.5/debian/ squeeze/main mariadb-server all 5.5.25-mariadb1~squeeze [2,966 B]                                                                       
Fetched 30.6 MB in 8s (3,587 kB/s)                                                                                                                                                                     
Preconfiguring packages ...
(Reading database ... 12642 files and directories currently installed.)
Removing mysql-server ...
Removing mysql-server-5.1 ...
Stopping MySQL database server: mysqld.
Removing mysql-client-5.1 ...
Removing mysql-server-core-5.1 ...
Processing triggers for man-db ...
Selecting previously deselected package mariadb-common.
(Reading database ... 12418 files and directories currently installed.)
Unpacking mariadb-common (from .../mariadb-common_5.5.25-mariadb1~squeeze_all.deb) ...
Selecting previously deselected package libmysqlclient18.
Unpacking libmysqlclient18 (from .../libmysqlclient18_5.5.25-mariadb1~squeeze_amd64.deb) ...
Selecting previously deselected package libmariadbclient18.
Unpacking libmariadbclient18 (from .../libmariadbclient18_5.5.25-mariadb1~squeeze_amd64.deb) ...
Selecting previously deselected package mariadb-client-core-5.5.
Unpacking mariadb-client-core-5.5 (from .../mariadb-client-core-5.5_5.5.25-mariadb1~squeeze_amd64.deb) ...
Selecting previously deselected package mariadb-client-5.5.
Unpacking mariadb-client-5.5 (from .../mariadb-client-5.5_5.5.25-mariadb1~squeeze_amd64.deb) ...
Selecting previously deselected package libaio1.
Unpacking libaio1 (from .../libaio1_0.3.107-7_amd64.deb) ...
Selecting previously deselected package mariadb-server-core-5.5.
Unpacking mariadb-server-core-5.5 (from .../mariadb-server-core-5.5_5.5.25-mariadb1~squeeze_amd64.deb) ...
Processing triggers for man-db ...
Setting up mariadb-common (5.5.25-mariadb1~squeeze) ...
Selecting previously deselected package mariadb-server-5.5.
(Reading database ... 12567 files and directories currently installed.)
Unpacking mariadb-server-5.5 (from .../mariadb-server-5.5_5.5.25-mariadb1~squeeze_amd64.deb) ...
Selecting previously deselected package mariadb-client.
Unpacking mariadb-client (from .../mariadb-client_5.5.25-mariadb1~squeeze_all.deb) ...
Selecting previously deselected package mariadb-server.
Unpacking mariadb-server (from .../mariadb-server_5.5.25-mariadb1~squeeze_all.deb) ...
Processing triggers for man-db ...
Setting up libaio1 (0.3.107-7) ...
Setting up libmysqlclient18 (5.5.25-mariadb1~squeeze) ...
Setting up libmariadbclient18 (5.5.25-mariadb1~squeeze) ...
Setting up mariadb-client-core-5.5 (5.5.25-mariadb1~squeeze) ...
Setting up mariadb-client-5.5 (5.5.25-mariadb1~squeeze) ...
Setting up mariadb-server-core-5.5 (5.5.25-mariadb1~squeeze) ...
Setting up mariadb-server-5.5 (5.5.25-mariadb1~squeeze) ...
Installing new version of config file /etc/mysql/debian-start ...
Installing new version of config file /etc/init.d/mysql ...
Stopping MariaDB database server: mysqld.
Starting MariaDB database server: mysqld ..
Checking for corrupt, not cleanly closed and upgrade needing tables..
Setting up mariadb-client (5.5.25-mariadb1~squeeze) ...
Setting up mariadb-server (5.5.25-mariadb1~squeeze) ...

root@v1421:~# mysql -e 'show global variables like "version";'
+---------------+-------------------------------------+
| Variable_name | Value                               |
+---------------+-------------------------------------+
| version       | 5.5.25-MariaDB-mariadb1~squeeze-log |
+---------------+-------------------------------------+
 
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.