When I create backup of all databases in MongoDB (version 3):
mongodump --username bacUser --password 12345
It\'s OK. But when I try to cre
If you still get same error with --authenticationDatabase admin , than probably your username and password are incorrect. Try adding a user db.createUser() , with appropriate role ( i gave write permission as well)
than run below command : (ignore -h if you are running on local)
mongodump -h : -d db_name -u newUser -p newPassword -o /home/mongodump/
Hope this helps...