wiki:mongodb_require_password
Table of Contents
mongodb require password
In /etc/mongod.conf add:
security.authorization: enabled
then enter mongo:
mongo
use admin
db.createUser( { user: "root", pwd: "sql", roles: [ { role: "root", db: "admin" } ] } )
Tested on
See also
References
wiki/mongodb_require_password.txt · Last modified: 2022/10/15 11:39 by antisa