MongoDb, Cloning database error: illegal argument combination: cannot specify --db and --uri MongoDb, Cloning database error: illegal argument combination: cannot specify --db and --uri mongoose mongoose

MongoDb, Cloning database error: illegal argument combination: cannot specify --db and --uri


You have to add db in URI- like connection uri/[db]

mongodb+srv://hihi:password@cluster0.fklgt.mongodb.net/test_db


mongodump --uri mongodb+srv://hihi:password@cluster0.fklgt.mongodb.net/test_db --archive="mongodump-test-db" 

https://docs.mongodb.com/v3.6/reference/program/mongodump/#cmdoption-mongodump-uri

/database Optional. The name of the database to authenticate if the connection string includes authentication credentials in the form of username:password@. If /database is not specified and the connection string includes credentials, the driver will authenticate to the admin database. See also authSource.

https://docs.mongodb.com/v3.6/reference/connection-string/