Dennis Zheleznyak

Dennis Zheleznyak

DevOps Engineer bigpanda

© 2021

Backup and Restore MongoDB

There are many ways to backup and restore MongoDB, I found this to be the easy one.

To dump ALL of MongoDB’s databases, use the following:

mongodump --archive=server.archive --gzip -j 24

To restore this dump:

mongorestore --archive=server.archive --gzip


  • –gzip - compress the archive file
  • -j 24 - dump 24 collections simultaneously