Howto: Make consistent MySQL database backups using Solaris ZFS snapshots

Posted on in Categories Howto, MySQL, Solaris, UNIX last updated August 20, 2007

I’ve already written about MySQL backup using a shell script and consistent backup with Linux Logical Volume Manager (LVM) snapshots:

A snapshot volume is a special type of volume that presents all the data that was in the volume at the time the snapshot was created. This means you can back up that volume without having to worry about data being changed while the backup is going on, and you don’t have to take the database volume offline while the backup is taking place.

Niclas has posted a nice howto about consistent MySQL backups using Solaris UNIX ZFS snapshots:

In this article I will show you how to install MySQL on a ZFS file system and supply you with a script to make consistent snapshots of the databases. This script may not be 100% fit for busy sites but for most smaller places I think it is perfect.

Posted by: Vivek Gite

The author is the creator of nixCraft and a seasoned sysadmin and a trainer for the Linux operating system/Unix shell scripting. He has worked with global clients and in various industries, including IT, education, defense and space research, and the nonprofit sector. Follow him on Twitter, Facebook, Google+.

2 comment

  1. If you use LVM, than you can implement “block level incremental forever” to IBM Spectrum Protect, using “Snap Protector”.
    This also reduces the backup space, as you can use this in combination with compression and de-duplicatioin techniques.

    I used this as a PoC for a big customer with a 5TB database, where they had a need to backup the database every hour to another site location for Disaster Recovery purposes. This solutions was able to backup the databases within minutes to another site locaiton, and they could still restore from the DR in minutes

Leave a Comment