MySQL Backup Setup


SnapShooter enables you to create and schedule backups for your MySQL databases using the same awesome interface that you use to schedule Droplet backups. Once setup, you can schedule backups with the familiar granularity of 1, 2, 3, 4, 6, 12, and 24 hour intervals.

A big advantage of our MySQL backup product is the choice of backup storage location. Currently, you can back up to your Digital Ocean account using Digital Ocean spaces, or you can back up to an AWS S3 bucket. (Other S3 compatible providers coming soon!)

We know that many of our customers are concerned primarily with the regular, scheduled backup of their MySQL databases. We are happy we can now offer a more targeted product that can address our customers specific needs, and provide them with extra peace of mind.

How it Works

We securely connect to a server of your choosing via SSH. From there, we run a mysqldump command against your chosen database (which may or may not be on the same host). Once that command has completed, we compress the output and upload it to your storage provider.

Much like droplets, we manage the process of creating and pruning of backups on a schedule, and provide tools to download or delete individual MySQL database backups.

We take customer security very seriously at SnapShooter. With that in mind:

  • The SSH user you provide us is generated a unique key pair and the user who performs the backup only needs limited permissions. expand on permissions
  • Provided AWS IAM keys only need the following IAM permissions:

    • s3:ListBucket
    • s3:DeleteObject
    • s3:GetObject
    • s3:PutObject
    • s3:PutObjectAcl

    Sample policy is available here

  • All access keys and SSH keys are encrypted.
  • We never store your database dump on our systems.

Getting Setup

  1. From the MySQL area of the dashboard press Setup New MySQL Backup
  2. Provide the servers SSH details
    1. Friendly name for the backups
    2. SSH Host (IP or hostname)
    3. The SSH user (if you would like to setup a new user follow this guide)
    4. SSH port (Usually 22)
  3. SnapShooter will generate a 4096 bit key pair
  4. Install the key pair SnapShooter provides a command you can run to perform the installation. Install SnapShooter mysql Key Pair
  5. Test setup
    • If everything worked as expected you will be asked for MySQL details. Otherwise, you will be displayed the output from the SSH connection to help you diagnose any SSH issues.
  6. Provide Mysql Authentication details

    Mysql Details

    • SnapShooter will check the connection and return a helpful error if something needs fixing.
  7. Select MySQL Database Choose MySQL backup database
    • If the database you wish to back up is not appearing, make sure the supplied MySQL user has the correct permissions to view and use the database and then refresh the page.
  8. Choose Storage
    • If you don't have an storage provider set up, you will be prompted to setup a new provider. here
    • Select the storage provider you wish to use to store backups.
    • If you only have one storage provider set up, that one will be chosen by default.
  9. Choose Schedule
    • Depending on which plan you are on, the options might be different.
    • Free users can only select daily backups.
    • Choose how often you want backups to run.
    • Choose timezone and time offset.
    • Retention Policy
      • Choose the number of backups you wish to store (only an option if you have scheduled more frequently than daily)
      • Choose number of daily snapshots you wish to retain.
      • Choose number of weekly snapshots you wish to retain.
      • Choose number of monthly snapshots you wish to retain.