How to Upgrade MariaDB 5.5 to MariaDB 10.1 on CentOS/RHEL 7 and Debian Systems

Best Affordable Linux and WordPress Services For Your Business
Outsource Your Linux and WordPress Project and Get it Promptly Completed Remotely and Delivered Online.

If You Appreciate What We Do Here On TecMint, You Should Consider:

  1. Stay Connected to: Twitter | Facebook | Google Plus
  2. Subscribe to our email updates: Sign Up Now
  3. Get your own self-hosted blog with a Free Domain at ($3.45/month).
  4. Become a Supporter - Make a contribution via PayPal
  5. Support us by purchasing our premium books in PDF format.
  6. Support us by taking our online Linux courses

We are thankful for your never ending support.

Marin Todorov

I am a bachelor in computer science and a Linux Foundation Certified System Administrator. Currently working as a Senior Technical support in the hosting industry. In my free time I like testing new software and inline skating.

Your name can also be listed here. Got a tip? Submit it here to become an TecMint author.

RedHat RHCE and RHCSA Certification Book
Linux Foundation LFCS and LFCE Certification Preparation Guide

You may also like...

11 Responses

  1. RyRy says:

    Regarding the dependencies, removing via rpm command without blowing up dependencies:

    # rpm -e --nodeps mariadb mariadb-libs mariadb-server

    Then yum install the packages. MariaDB-Shared replaces mariadb-libs which is what postfix, etc needs.

    You will then find the packages are satisfied:

    # yum deplist postfix

    and you will see the MariaDB-Shared is a accepted provider.

  2. Kirt HAll says:

    Thanks everyone for your tips and advice. I was able to recovered my previously existing databases by adding the datadir parameter to the my.cnf file. I then restarted the database and all was good. Interestingly enough I later had to remove this references from the my.cnf because of startup errors but the database does not lose its relationships with the databases. This I can not explain.

  3. K Hall says:

    Upgraded MariaDB5.5 to 10.0 following these steps including removal of MariaDB. I then used yum to install mariadb10.0. This went without error. I then started the MariaDB service and it showed the correct version.

    However, the previously existing database was not found. How do I re-attach the old database to the new database engine so I can run the upgrade procedure against it? The old data files are still available.

    • Ravi Saive says:


      You can import your database and run mysql_upgrade command to upgrade the database structures with new engine..

  4. Brian says:

    Did you notice that this article removes postfix, which has a dependency on mariadb-libs? You don’t address reinstalling postfix at all.

  5. David says:


    Removing the dependencies broke a lot of things for me. So I’ve done this, which seems to work:

    # just remove mariadb-server, removing other packages breaks lots of things
    yum remove mariadb-server

    # update other maria packages
    yum update -y

    # install mariadb-server v 10.1
    yum install mariadb-server

    # start and enable mariadb
    systemctl start mariadb
    systemctl enable mariadb

    # upgrade DBs
    mysql_upgrade -uroot -ppassword

  6. mojo706 says:

    How do I put back whatever I had backed up

  7. alex says:

    after i upgrade mysql my sentora panel stop working.
    sudo /usr/bin/php -q /etc/sentora/panel/bin/daemon.php
    PHP Warning: PHP Startup: Unable to load dynamic library ‘/usr/lib64/php/modules/’ – /usr/lib64/php/modules/ undefined symbol: php_register_info_logo in Unknown on line 0
    PHP Fatal error: Undefined class constant ‘MYSQL_ATTR_INIT_COMMAND’ in /etc/sentora/panel/inc/ on line 28

    Can you help me to fix plz.

Got something to say? Join the discussion.

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.