赞
踩
控制台报“Command failed with error 18: ‘Authentication failed.’”只需在所需要操作的数据库中添加一个用户,具体操作方式如下
db.createUser({user:"userName",pwd:"userPassword",roles:[{role:"readWrite",db:"dbName"}]})