mongod --auth --logpath "D:\Program Files (x86)\Web\mongodb\log\log.log" --logappend --dbpath "D:\Program Files (x86)\Web\mongodb\data\db" --directoryperdb --reinstall
db.createUser( { user: "maclean", pwd: "maclean", roles: [ { role: "__system", db: "admin" } ] } )
grant all privileges on *.* to [email protected] identified by ’1’
时间: 2024-10-18 16:29:18