Howto: Make consistent MySQL database backups using Solaris ZFS snapshots

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

ADVERTISEMENTS

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.

🐧 Get the latest tutorials on SysAdmin, Linux/Unix, Open Source & DevOps topics via:
CategoryList of Unix and Linux commands
File Managementcat
FirewallCentOS 8 OpenSUSE RHEL 8 Ubuntu 16.04 Ubuntu 18.04 Ubuntu 20.04
Network Utilitiesdig host ip nmap
OpenVPNCentOS 7 CentOS 8 Debian 10 Debian 8/9 Ubuntu 18.04 Ubuntu 20.04
Package Managerapk apt
Processes Managementbg chroot cron disown fg jobs killall kill pidof pstree pwdx time
Searchinggrep whereis which
User Informationgroups id lastcomm last lid/libuser-lid logname members users whoami who w
WireGuard VPNCentOS 8 Debian 10 Firewall Ubuntu 20.04

ADVERTISEMENTS
2 comments… add one
  • nkalubo charles Oct 1, 2015 @ 9:20

    i have not been helped

  • Tomas Nov 14, 2016 @ 12:09

    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 Reply

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

Use HTML <pre>...</pre>, <code>...</code> and <kbd>...</kbd> for code samples.