The post-thaw script will not run until the snapshot is created. Stop the MySQL service for a few moments while the snapshot is created, then start it again. Option 2: Hot MySQL/MariaDB backup - Database freezing A second copy of the database means extra storage space is required to maintain it. As with Option 1, the pre-freeze-script will only run if you have the VMware tools running.Īdvantage: This allows for 100% uptime the MySQL service does not stop and the dumped databases are in a transaction-consistent state.ĭisadvantage: Depending on the size of your databases, the process may take a considerable amount of time to achieve. This method lets you take a transaction consistent backup of databases but more steps are needed to perform a restore. The mysqldump command copies a database to storage accessible from the MySQL server, taking an online dump of each database without disrupting the MySQL service. Here’s a quick summary: Option 1: Hot MySQL/MariaDB backup - Database online dump VMware can run a script to act before the snapshot is created, known as the pre-freeze script and can run a script to do things after the snapshot is created, known as the post-thaw script.
It is not straightforward like a Microsoft SQL quiescence, because Linux doesn’t have a VSS mechanism like Windows does.ĭescribed are methods of creating a MySQL/MariaDB backup on a Linux VM using activated scripts local to the database. This makes use of VMware tools installed on the Linux VM. Two hot backup methods running pre- and post-snapshot scripts, and cold backup using database shutdown.
The paper is available for download on our website and describes three different methods for MySQL/MariaDB backup on a Linux VM. The answers can be found in our popular white paper Consistent protection of MySQL/MariaDB with Veeam, written by Solutions Architect Pascal Di Marco. What does it take to back up MySQL on a Linux VM? This is a riddle we sometimes hear at Veeam: When running on a Linux VM, how does one quiesce MySQL databases? Unfortunately, there are not many new ways to answer this riddle, and the answers we currently have are already tried and tested!