1
I’m starting in mongodb, linux platform. would like to know what the best backup strategy since:
Data import and Export - are used for cvs or json outputs Mongodump and Mongorestore - are used for small bases.
Anyway, what is the best tool?
1
I’m starting in mongodb, linux platform. would like to know what the best backup strategy since:
Data import and Export - are used for cvs or json outputs Mongodump and Mongorestore - are used for small bases.
Anyway, what is the best tool?
1
To official documentation page mentions several ways. Disregarding the official maintenance tool, the Cloud Manager which is paid for per server, you have two options (three depending on the operating system/infrastructure):
The dump/Restore works well only on small bases because the complexity that is added when you have multiple shards, for example, makes it impossible to manage the integrity/synchronization of backups.
If you are running a replication set (replica set), I see no problem backing up with dump/Restore. Whereas you use the --oplog option so that changes that are being made during the dump are included, and then in the Restore use --oplogReplay.
Copying the files manually involves stopping any writing to the server(s) as you are copying multiple files, and this is not an atomic operation.
In the case of snapshots you can use without problems as long as journaling is active (it is the default), without this there is no guarantee that your snapshot will be valid. If you use this option in a sharded cluster, you need to stop Alancer and snapshot all shards and configuration servers at approximately the same time.
Browser other questions tagged database mongodb
You are not signed in. Login or sign up in order to post.