Security is very important in production deployment, let's see how do we execute a dump in mongoDB
./mongodump --host dbh85.test.com --db mydatabase --collection user -u username1 -p ultrasecretpass
In this case we expose username and password, that's not good.
we could have 2 problems if some intruder get this credencials:
Data changes would be cover with read-only users, but I still have the data theft problem.
mysql has a -defaults-extra-file option which is very useful for theses cases, for instance:
defaults-extra-file=/home/daniel/protectedlogin.cnf -all databases
where protectedlogin.cnf contains the credentials encrypted.