Percona-Lab / mongodb_consistent_backup

A tool for performing consistent backups of MongoDB Clusters or Replica Sets
https://www.percona.com
Apache License 2.0
276 stars 81 forks source link

Fix for mongorestore problem #318

Closed ReyanshKharga closed 4 years ago

ReyanshKharga commented 5 years ago

mongorestore doesn't work without --gzip option if it was dumped with --gzip option. It throws the following error: Failed: restore error: error reading oplog bson input: unexpected EOF Source of solution

The correct mongorestore command should be: mongorestore --host mongod12.example.com --port 27017 -u admin -p 123456 --oplogReplay --gzip --dir /var/lib/mongodb-consistent-backup/default/20170424_0000/rs0/dump

ReyanshKharga commented 4 years ago

Thanks for accepting the pull request Percona-Lab!