Virtualmin upgrade MariaDB 5.5 to 10.2

webmin-logoWebmin hosts on CentOS 7 come with MariaDB 5.5 by default. If you need to upgrade it MariadDB the following guide will help you to do this step-by-step. Prior to start an upgrade MariaDB 5.5 to 10.2 on the Webmin host there will be a few preliminary but very important steps.

Before you do anything make a backup of your current databases:

Also make a backup of your /etc/my.cnf file (you can always get the default one from /usr/share/mysql).

Now you can stop and uninstall the current mariadb packages:

Create a file /etc/yum.repos.d/MariaDB.repo , copy and paste the code below inside it.

Save the /etc/yum.repos.d/MariaDB.repo then install mariadb 10.2:

Start the mysql service:

Run the upgrade for databases and tables:

Restore your my.cnf you made a backup of or use one of the examples in the directory i mentioned above. (if you happen to use the example, remove the innodb_additional_mem_pool_size line as it’s no longer being used)

Your mysql service has now been upgraded to 10.2 without issue. The MySQL area will be able to read the config file.

Now you may have noticed that during the uninstall that postfix was also uninstalled along with mariadb 5.5. This indeed happened however luckily it created a backup for the main, virtual and master configuration before uninstallation.

Go to your Webmin CP -> Servers -> Postfix Mail Server It will say that it’s not installed, click the install button for it to reinstall now go back to “Postfix Mail Server” settings and go to “Edit Config Files”

In the dropdown go to main.rpmsave, virtual.rpmsave and master.rpmsave and copy/paste each one to their respective default file.

If you also installed dkim-filter, it would have also created a backup file of dkim-filter.conf.rpmsave so just apply the same thing there (i assume there’s not in house editor so you’ll have to restore via ssh).

Congratulations! You have successfully upgraded MariaDB 5.5 to 10.2

Want me to do this for you? Drop me a line: itgalaxyzzz {at} gmail [point] com