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
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 solutionThe 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