New Utility: MariaDB Backup / Recovery Agent

I’m happy to announce openemr-devops/utilities/mariadb-backup-manager at master · openemr/openemr-devops · GitHub has gone live – it’s a sequel to the Percona XtraBackup wrapper that the appliances use, but for MariaDB instead of MySQL. It’s designed to work with containerized instances of MariaDB specifically running in Docker Compose, and it’s able to handle recovering the same, which involves enough tinkering that I think a lot of users just resorted to mysqldump instead.

Features:

  • hot, consistent backups without downtime
  • full and incremental backups at your schedule
  • supports bind mounts to exfiltrate backups to the host
  • clean recovery with one command
  • rotation and pruning

To be honest, there’s nothing OpenEMR-specific about this, I just wrote it because apparently nobody else had. It’s suitable for any project running MariaDB, and customizable with very little effort if your environment has needs beyond the general case.

Next step: Migrating the appliance scripts (Lightsail, Express, Express Plus) to use this tool and MariaDB instead of the current MySQL and move off the customized MySQL containers we’re maintaining.

3 Likes