Databases & Backups

Backups & Restore

Run, schedule, download, and restore database backups — with optional offsite copies to S3.

Every database engine DeployOS supports (Postgres, MySQL, MongoDB, Redis, MSSQL) can be backed up and restored from the Backups page.

Running a backup manually

Click Run on a database. DeployOS runs the correct native dump tool for that engine (pg_dump, mysqldump, mongodump, a Redis SAVE, or sqlcmd BACKUP for MSSQL) and stores the result on the server under /opt/deployos/backups/{name}.

Scheduling backups

Set a cron schedule and retention count per database — the Daily 02:00 preset covers the common case. Older backups beyond your retention count are pruned automatically.

Offsite backups (S3)

Configure an S3-compatible offsite target (bucket, endpoint, and keys — keys are stored in your OS keychain) from the Backups page. Once set, both manual and scheduled backups push a copy offsite via restic after the local dump completes — so a backup isn't only as safe as the server it was taken on.

Restoring

Pick a backup from the list and click Restore — you'll be asked to confirm, since this overwrites the target database's current data. Restore works against the same server the backup was taken on, or a different one if you're recovering onto a replacement machine.

Downloading backups locally

Back up & download DBs, from a server's quick-actions menu, pulls the newest backup of every database on that server down to ~/Downloads/DeployOS-backups/ on your own machine. While DeployOS is open, this also runs automatically in the background every few hours, so a reasonably recent local copy always exists without you remembering to grab one.

💡 Tip — offsite S3 push and the local Downloads mirror are two separate safety nets; use both if the data genuinely matters. A backup that only lives on the server it's protecting doesn't survive that server dying.

Backing up more than one database at once

Everything above is per-database. To back up an entire server — every app's data, not just one database — see Server Snapshots & Wipe, which reuses this same S3 offsite target.