Recall & Review
beginner
What is the purpose of a backup in MongoDB?
A backup is a copy of your database data saved separately. It helps you recover data if something goes wrong, like accidental deletion or hardware failure.
Click to reveal answer
beginner
Name two common backup methods in MongoDB.
1. mongodump: creates a binary export of the database.<br>2. File system snapshot: copies the database files directly while MongoDB is stopped or using journaling.
Click to reveal answer
intermediate
What is the role of the oplog in MongoDB backup and restore?
The oplog (operation log) records all changes to the data. It helps in point-in-time recovery by replaying changes after restoring a backup.
Click to reveal answer
beginner
How does mongorestore work?
mongorestore reads data from a mongodump backup and inserts it back into a MongoDB database, restoring collections and documents.
Click to reveal answer
intermediate
Why is it important to test your backup and restore process?
Testing ensures your backups are valid and can be restored successfully. It prevents surprises during real data loss events.
Click to reveal answer
Which MongoDB tool is used to create a binary backup of the database?
✗ Incorrect
mongodump creates a binary backup of the database data.
What does the oplog help with during restore?
✗ Incorrect
The oplog records all changes and helps replay them to restore data to a specific point in time.
Which backup method requires stopping MongoDB or using journaling?
✗ Incorrect
File system snapshots copy database files and usually require MongoDB to be stopped or use journaling to ensure consistency.
What is the main purpose of mongorestore?
✗ Incorrect
mongorestore loads data from a mongodump backup back into MongoDB.
Why should you regularly test your backups?
✗ Incorrect
Testing backups confirms they are valid and can be restored when needed.
Explain the main backup strategies available in MongoDB and when you might use each.
Think about tools and how MongoDB data files can be copied safely.
You got /4 concepts.
Describe the role of the oplog in MongoDB backup and restore processes.
Consider how changes are tracked and replayed.
You got /3 concepts.