MongoDB
- Canonical
- Databases
Channel | Revision | Published | Runs on |
---|---|---|---|
6/stable | 199 | 04 Oct 2024 | |
6/candidate | 199 | 04 Oct 2024 | |
6/beta | 199 | 04 Oct 2024 | |
6/edge | 206 | 13 Dec 2024 | |
5/stable | 117 | 20 Apr 2023 | |
5/candidate | 117 | 20 Apr 2023 | |
5/edge | 139 | 21 Nov 2023 | |
5/edge | 109 | 06 Mar 2023 | |
3.6/stable | 100 | 28 Apr 2023 | |
3.6/candidate | 100 | 13 Apr 2023 | |
3.6/edge | 100 | 03 Feb 2023 |
juju deploy mongodb --channel 6/stable
Deploy universal operators easily with Juju, the Universal Operator Lifecycle Manager.
Platform:
How to restore a backup
This is a guide on how to perform a basic restore of a local backup of your Charmed MongoDB replica set or sharded cluster.
Prerequisites
- A replica set with at least three nodes deployed OR a sharded cluster with at least one shard deployed
- Configured settings for S3 storage
- An existing backup in your S3 storage
Summary
Determine the application to run backup actions on
The application to pass to juju
when running backup and restore actions depends on whether your deployment is a replica set or sharded cluster:
When running Charmed MongoDB as a replica-set, this will be the name of your MongoDB application.
When running Charmed MongoDB as a sharded cluster, this will be the name of your MongoDB application running with the “config-server
” role - never the shard applications.
List all backups
To list all backups available, run:juju run <replica-set name | config-server name>/leader list-backups
This will display available backups similar to the output below:
backup-id | backup-type | backup-status
----------------------------------------------------
YYYY-MM-DDTHH:MM:SSZ | logical | finished
Restore a backup
Before restoring a backup, check that your Charmed MongoDB deployment is
active
andidle
withjuju status
.
To restore a backup from the list, run the restore
command using the backup-id
:
juju run <replica-set name | config-server name>/leader restore backup-id=YYYY-MM-DDTHH:MM:SSZ
The restore will now be in progress.