Reputation: 509
I have MongoDB backup that was created in following way:
mongodump -h <host> -u <user> --password=<password> -d <db_name> --authenticationDatabase <db_name> --archive=<backup_name>.gz --gzip
When I’m restoring the backup using “mongorestore” all the DB content is being restored. I’m looking for a way to restore only specific collection from the backup to a new or same DB.
I’ve tried to use --nsInclude
, --nsFrom
and --nsTo
flags, but they aren’t helping.
Is there any possible way to achieve what I’ve described above?
Upd:
I've tried following:
Upvotes: 0
Views: 51