-
Type: Task
-
Resolution: Gone away
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: mongorestore
-
(copied to CRM)
mongorestore accepts a replica set connection string for its --host argument. However, it only uses that connection string as a way to discover the current primary at the time of starting the restore. If a primary failover occurs during the restore, then mongorestore just logs a bunch of "error: EOF" and doesn't retry inserting the documents. Since the writes are being performed with w="majority" by default in a replica set, it should be possible to have mongorestore automatically retry the insert commands on network errors, "not master" errors, etc., and to ignore any resulting DuplicateKey error responses the server may return.
The current behavior of mongorestore has made it painful for me to migrate 1TB of data over to a new Atlas cluster.
- related to
-
TOOLS-2246 --stopOnError and --maintainInsertionOrder do not work as expected
- Closed