The basic how-to tutorial for migrating databases from Mysql to mariadb under Linux _mysql

Source: Internet
Author: User
Tags percona

Since 2012 years, Wikipedia has started migrating from MySQL to Mariadb, a major milestone in the evolution of the Wikimedia database architecture, porting the English and German versions of the Wikipedia database Wikidata to MARIADB 5.5.
Over the past few years, Wikipedia has been using the MySQL 5.1 derivative version of Facebook as our product database, and the build version number is r3753. We are delighted with the performance of the product, with Facebook having the best database engineers in the world who have brought a lot of improvements to the MySQL ecosystem.

Now the enhancements to the MARIADB optimizer, the Percona xtradb features, and some of the reasons for Oracle 5.5 have prompted us to consider the issue of upgrades. It is also important that, as a supporter of the Free Culture movement, the Wikimedia Foundation is strongly interested in using free software projects and does not want to use different licenses to differentiate between free and Enterprise editions, and we welcome and support the work of the MARIADB Foundation as a non-profit organization on the MySQL-related database community.

We did a lot of preparation, including compatibility testing and performance testing, before we made a formal move, see official instructions for details.

MySQL is the world's most popular open source relationship data, its name from the founder of Michael "Monty" Widenius's eldest daughter "my". In 2008, when Sun acquired mysql;2009, Oracle bought Sun,mysql into Oracle, which had strained relations with the open source community. Widenius and his old team created the MySQL branch mariadb at the beginning of the 2009, its name was taken from Widenius's daughter "Maria", who hopes to challenge Oracle's MySQL by retaining core developers and growing community help mariadb.

The worsening relationship between Oracle and the open source community is prompting many distributions to replace MySQL with MARIADB, and now the popular web site Wikipedia, which uses MySQL, also announces a move from MySQL to Mariadb, in part because Oracle's MySQL has a free version and an enterprise version, And the enterprise version of the new features are not open source, and mariadb is not the problem.

ArchLinux has announced that it will use MARIADB as the default provider for MySQL, openSUSE has already used the default MARIADB in the recently released version 12.3, and even Fedora is considering replacing it with mariadb ....
Next, let's take a look at the practical ways to migrate from MySQL to mariadb in a Linux environment.

It's easy for Arch users to follow the official news:

Systemctl Stop mysqld 
pacman-s mariadb libmariadbclient mariadb-clients 
systemctl start mysqld 
mysql_ Upgrade-p 

And for OpenSUSE is more fool type, after all, is the default well: Zypper in mariadb a sentence is enough.

As for Debian/ubuntu users, it's a bit more complicated, but the whole process is smooth:

First go to MARIADB's official Repository Configuration Tool to select a suitable source, and then place the given address at the bottom of the/etc/apt/sources.list file:

# MARIADB 5.5 repository list-created 2013-03-26 14:20 UTC 
# http://mariadb.org/mariadb/repositories/ 
deb http: Mirror2.hs-esslingen.de/mariadb/repo/5.5/debian Squeeze main 
deb-src http://mirror2.hs-esslingen.de/mariadb /repo/5.5/debian Squeeze Main 

Next, execute the following command:
Apt-key adv--recv-keys--keyserver keyserver.ubuntu.com 0xcbcb082a1bb943db apt-get 
update 
Apt-get Mariadb-server mariadb-client 

As a result, MySQL (or Percona) is automatically uninstalled and replaced with MARIADB, and in some specific circumstances, these commands may need to be executed:

Apt-get autoremove 
apt-get Upgrade # or Apt-get Dist-upgrade 
mysql_upgrade-p 

And then it's done! Go ahead and toss it.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.