Skip to content

Overview

Svalbard is an open-source command-line tool for database backups, written in Rust. It backs up one PostgreSQL or MySQL database per run to Amazon S3, Cloudflare R2, another S3-compatible service, or an SSH server with SFTP or SCP. CI or cron owns the schedule. Svalbard has no server and no hosted control plane.

SourcesDestinations
PostgreSQL 15, 16, 17 and 18Amazon S3 and S3-compatible services
MySQL 8.4 and 9.7, InnoDBCloudflare R2
SSH servers, with SFTP or SCP
  1. Svalbard checks the configuration and the destination, without writing.
  2. It dumps the database from a snapshot with the native client, pg_dump or mysqldump, into a private staging directory. A watchdog ends the backup sessions when they block other sessions.
  3. It closes the snapshot and the database connections, and only then uploads the dump and its completion record.
  4. It deletes the staging directory. A backup is complete only when the dump and its record are both stored.
  • Install: the release archive, the native clients, or a build from source.
  • Configuration: the settings, their flags and environment variables, TLS and secrets.
  • Storage: the stored objects, and the S3, R2 and SSH destinations.
  • Back up: the stages, cancellation, the output and the exit codes.
  • Restore: the native restore of a backup.
  • Run in CI and the GitHub Action.
  • Database safety contract: the rules that protect the source database.
  • Development: checks, tests, releases and this website.

Svalbard is MIT licensed. The license covers the code, not the name or the logos: see trademarks. The source is on GitHub.