Expand my Community achievements bar.

Backup/restore with AEM 6.1 and MongoMK

Avatar

Level 1

Hi community,

We are setting up a new AEM 6.1 installation on-premise with a clustered author instance on MongoDB and we store blobs on a shared filesystem.

Our current infrastructure does not allow filesystem snapshots, but we like to implement hot backups.

Sadly enough, the official Adobe documentation on backup/restore is very poor for this combination.

Anyone out there have a working backup/restore procedure or any pointers on the best way to achieve this?

And how do we keep our MongoDB backup in sync with our filesystem backup?

5 Replies

Avatar

Level 10

Thanks for posting this question. We will log a bug on the docs so they are improved. I will make sure you get the proper information. 

Avatar

Employee

Hi,

While we await official documentation, I can add the following: you never mentioned if you are using a MongoDB replica set, in the page you reference Adobe recommends using the MongoDB tools to backup MongoDB. 

As for your external file datastore the official documentation mentions this "Because files in the file data store directory are immutable, they can be backed up incrementally (potentially using rsync) or after running the online backup". This should still hold true for AEM. 

The document your referenced also states: "The online backup only backs up the file system. If you store the repository content and/or the repository files in a database, that database needs to backed up separately. If you are using AEM with MongoDB, see documentation on how to use the MongoDB native backup tools." Given all of the above, I would suggest you can do an online backup of AEM, backup MongoDB, then lastly take a backup of your file datastore.

As this is an author system does it require 24/7 up time? If not, I'd suggest you also regularly perform cold backups of the whole system.

Regards,

Opkar

[0]https://docs.mongodb.org/manual/tutorial/backup-and-restore-tools/ 

[1]https://docs.adobe.com/docs/en/aem/6-1/administer/operations/backup-and-restore.html 

Avatar

Level 10

In addition - we got this info too:

I think that following should work:

  • Take backup of mongo db (using mongodump or MMS)
  • Take backup of FDS (assuming GS hasn't run between 1-2 steps)
  • Take backup of crx-quickstart folder using filesystem snapshot (or crx hot backup)

The sequence does matter. At least, the external data store needs to be backed up after the MongoDB. 

I'm not 100% sure about when to backup of the crx-quickstart folder; maybe it's better to do that at the very end. I'm not quite sure if there are any "important" files. 

But at least for the log files, it's probably better to copy them at the very end.

Avatar

Level 1

We do use a MongoDB replica set with 3 nodes and we use MongoDB Ops Manager to schedule the backups.

As we are a newsroom, yes we need to be up 24/7.

The problem is actually the scheduling. MongoDB Ops Manager doesn't allow to set a fixed time for the backup, so we're never sure the backup of FDS or crx-quickstart is after the MongoDB backup is finished. Any clues on that?

When restoring we had some issues with the Lucene Indexes which have a copy on the local filesystem (in the quickstart folder). AEM wouldn't start as they are out of sync. But as they are also in the MongoDB database, is it safe to delete them on restore?

Avatar

Level 9

Hi,

I believe there is a alert configuration on the MongoDB. There are many times of alerts like DB down time, Network issues etc. Also, backup alerts.

Have you tried configuring those?.

https://docs.cloud.mongodb.com/reference/alerts/#backup-alerts

---

Jitendra