This is a read-only copy of the MariaDB Knowledgebase generated on 2024-11-15. For the latest, interactive version please visit https://mariadb.com/kb/.

Migrating MySQL 5.5 Windows to MariaDB 10.x on new Windows server

My company is contemplating moving from MySQL 5.5 to MariaDB 10.x. We don't want to do an in place upgrade because the existing server is an older machine running Win 2003 x64. We have a new server that we're going to build out (don't know complete specs yet), and would like to know how we can best migrate the existing MySQL instance to a new instance of MariaDB on the new server.

Is it as simple as doing a mysqldump from the existing server and piping it into the new? I've read how to do it here: http://dba.stackexchange.com/questions/174/how-can-i-move-a-database-from-one-server-to-another are these answers adequate?

Answer Answered by Peter McLarty in this comment.

You should be able to set up your new server as a replica and then switch without the downtime, if your database takes a while to backup and restore with mysqldump this is likely a better way as you should be able upgrade to 10 with about 10 minutes downtime. I am assuming you are running innodb tables, it makes a difference to the impact to your system Step 1 install mysql 5.5 on your new server and restore a backup, using percona xtrabackup or take your dump and restore which you use to the new server and enable replication

Upgrade the slave to 10 Straight binary replacement and run mysql_upgrade

When you are happy it is working and your data is all good then you can make your replica the master and switch your app to point to your new server. Stop your application On 5.5 server issue FLUSH LOGS; Steps to switch on slave(aka new server) 1) STOP SLAVE; 2) RESET MASTER 3) remove the read only setting SET GLOBAL READ_ONLY=0; 4) Point your app to the new master 5) Log on to your old master server and shut down the database 6) put read-only=1 into the old server cnf so nothing can update it if restarted

Allow access to the the app and check it is all working. Depending on your app you might need to update your front end drivers

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.