Backup & Restore of Enterprise Manager

Note: This is about backing up the data, configuration and collected metrics of the Enterprise Manager (EM), not the databases.

Backing up Enterprise Manager Server

1

Stop the Enterprise Manager

  1. Go to the Enterprise Manager installation directory

  2. Run docker compose stop to stop the Enterprise Manager

2

Create a directory for backups

Create the `backups` directory
mkdir backups
3

Take a backup of all the volumes

Back up all volumes
docker run --rm --volumes-from enterprise-manager-grafana -v $(pwd)/backups/:/backups/ alpine:latest tar -czf /backups/grafana-backup.tar.gz /var/lib/grafana/
docker run --rm --volumes-from enterprise-manager-prometheus -v $(pwd)/backups/:/backups/ alpine:latest tar -czf /backups/prometheus-backup.tar.gz /prometheus/
docker run --rm --volumes-from enterprise-manager-supermax -v $(pwd)/backups/:/backups/ alpine:latest tar -czf /backups/supermax-backup.tar.gz /var/lib/supermax/

The backups directory now contains the data from the Enterprise Manager.

4

Start the Enterprise Manager

  1. Go to the Enterprise Manager installation directory

  2. Run docker compose up -d to start the Enterprise Manager

Restoring Enterprise Manager Server

1

Stop the Enterprise Manager

  1. Go to the Enterprise Manager installation directory

  2. Run docker compose stop to stop the Enterprise Manager

2

Restore the backup of all volumes

The backups are stored in the ~/backups/ directory.

Restore backup to all volumes
# Clear out any existing data first
docker run --rm --volumes-from enterprise-manager-grafana -v $(pwd)/backups/:/backups/ alpine:latest find /var/lib/grafana/ -delete -mindepth 1
docker run --rm --volumes-from enterprise-manager-prometheus -v $(pwd)/backups/:/backups/ alpine:latest find /prometheus/ -delete -mindepth 1
docker run --rm --volumes-from enterprise-manager-supermax -v $(pwd)/backups/:/backups/ alpine:latest find /var/lib/supermax/ -delete -mindepth 1

# Restore the data from the backups
docker run --rm --volumes-from enterprise-manager-grafana -v $(pwd)/backups/:/backups/ alpine:latest tar -C / -xzf /backups/grafana-backup.tar.gz
docker run --rm --volumes-from enterprise-manager-prometheus -v $(pwd)/backups/:/backups/ alpine:latest tar -C / -xzf /backups/prometheus-backup.tar.gz
docker run --rm --volumes-from enterprise-manager-supermax -v $(pwd)/backups/:/backups/ alpine:latest tar -C / -xzf /backups/supermax-backup.tar.gz
3

Start the Enterprise Manager

  1. Go to the Enterprise Manager installation directory

  2. Run docker compose up -d to start the Enterprise Manager

This page is: Copyright © 2025 MariaDB. All rights reserved.

Last updated

Was this helpful?