Disaster Recovery

This guide describes the backup and recovery concept for a Relution Server that uses a database (PostgreSQL or MariaDB) and optionally integrates an on-premises S3-compatible storage system (such as SeaweedFS, see Object Storage for Relution →).

The goal is to ensure data integrity, minimize downtime (RTO), and guarantee reliable restorability in an emergency.

The configuration of backup automation, monitoring, and ensuring the backups are performed is the responsibility of the customer.

Components to Back Up

The Relution infrastructure typically consists of the following components that need to be backed up:

  • Application Server: Hosts the Relution application and services.
  • Database (On-Premises): MariaDB or PostgreSQL.
  • S3 Storage (On-Premises): Object-based storage system (optional) for storing files (e.g., app packages and uploaded resources). Without S3, Relution stores this content in the database; the database backup then also covers all files.
All applications can also be operated together on a single machine. The use of S3 Storage is optional, but if used, operation of the Relution Server is impossible without the contents of the S3 Bucket.

Backup Goals

  • Minimizing data loss (RPO – Recovery Point Objective)
  • Fast restoration of services (RTO – Recovery Time Objective)
  • Protection against hardware failure, software errors, and human errors
  • Protection against data manipulation and ransomware

1. Database Backup

StrategyDetails
FrequencyDaily full dumps (e.g., via mariadb-dump or pg_dump)
IncrementalHourly incremental backups (depending on necessity)
ManagementAutomated rotation and retention rules
SecurityEncryption of backup files (AES256 or GPG) depending on necessity
ConsistencyDuring the backup, the Relution service should be temporarily stopped to avoid inconsistencies!

2. S3 Storage Backup (Optional)

StrategyDetails
MethodReplication to a second S3 target or regular syncing (s3cmd sync, rclone sync)
ScopeBackup of critical buckets at defined intervals
ConsistencyDuring the backup, the Relution service should be temporarily stopped to avoid inconsistencies!

3. Server Configuration Backup

All relevant configuration files must be backed up:

  • /opt/relution (Directory of the Relution Server)
  • compose.yaml, or docker-compose.yml for older installations (or comparable startup scripts)
  • application.yml (Relution configuration)
  • NginX configuration file, if applicable
  • SSL certificate and key
  • Keys for encrypted data, if configured (see the following note)
Back up keys separately: If an external key encryption key (KEK) is configured for database encryption (relution.database.crypto.keks), or an SSE-C key or key file (keyFile, see Server-Side Encryption (SSE-C) →) is configured for the object storage, the database or bucket backup cannot be restored without these keys. The keys are often not stored in application.yml, but in environment variables, an .env file or a secret store. They are kept separately from the data backups. After a KEK change, the old key is retained for as long as older database backups exist. Without an external KEK, Relution generates the key itself and stores it in the database; in this case the database backup is sufficient.

Backup Storage Locations

Adherence to the 3-2-1 backup principle is recommended:

  • 3 copies of the data
  • 2 different systems/media
  • 1 copy external/offsite

Time Schedule

IntervalBackup
DailyFull database backup
HourlyIncremental DB backup (depending on necessity)
DailyS3 sync of critical buckets
WeeklyFull server configuration backup

Further Aspects

AreaDetails
AutomationCron jobs or systemd timers; Logging all processes; Notifications on errors
EncryptionEncryption of all backups; TLS/HTTPS/SSH for transport
Integrity CheckMonthly test restore

1. Database Recovery

  1. Selection of the correct backup file
  2. Preparation of the target system (stopping the Relution service; the database service must be running, create an empty database if necessary)
  3. Data import (e.g., via psql or mysql)
  4. Functional test of the Relution application

The restore uses the same Relution version that was installed at the time of the backup. Database updates only run forward; an update to a newer version is then performed as usual (see Update →). A configured external KEK must be available again when Relution starts.

A downgrade, i.e. starting an older Relution version with an already updated database, is not supported and can lead to data loss or unexpected behavior. Returning to an earlier version is therefore only possible by restoring a backup that was created with that version.

2. S3 Storage Recovery

  1. Selection of the objects/buckets
  2. Restoration via rclone, s3cmd, or API
  3. Integrity check (verification that the files are available in Relution)

3. Full System Recovery

  • Restoration of configurations (from the server configuration backups).
  • Restart of all services.
  • Functional test of the complete application.

Monitoring & Alerting

  • Monitoring of all backup processes (e.g., with tools like Grafana + Prometheus).
  • Alerting for:
    • Backup errors
    • Low disk space
    • Integrity errors
    • Test-restore failures

Security

  • Access restrictions (Least Privilege principle).
  • Secure storage of keys and credentials.
  • Regular updates of the software used.

Documentation

  • Documentation of all process changes (configuration, schedules).
  • Clear responsibilities for backup and restore.
  • Log data retention for at least 90 days.

Conclusion

This backup concept ensures that both the database and the on-premises S3 storage system are reliably protected and can be quickly restored in an emergency. Through automation and regular checks, operational security is guaranteed long-term.

How helpful was this article?