mongorestore: don't know what to do with subdirectory "dump/mydb", skipping

63 Views Asked by At

I have taken a mongodump of a specific db from a Mongo cluster as follows:

mongodump mongodb+srv://<username>:<password>@mongo-uri/mydb

This created a dump/mydb directory.

Now I am trying to restore it to another Mongo cluster more or less as follows

mongorestore mongodb+srv://<new_username>:<new_password>@new-mongo-uri/mydb

The process fails with

don't know what to do with subdirectory "dump/mydb", skipping...

I have also tried

mongorestore mongodb+srv://<new_username>:<new_password>@new-mongo-uri -d mydb

same result

How is the correct format for the command?

0

There are 0 best solutions below