下面是我启动mongo shell并尝试查看哪些dbs,尝试同时使用bitnami和ubuntu作为用户,以及bitnami root用户的root pwd以及我可以尝试使用好。
MongoDB shell version v3.4.2
connecting to: mongodb:///opt/bitnami/mongodb/tmp/mongodb-27017.sock/
MongoDB server version: 3.4.2
> show dbs;
2017-11-08T07:14:01.123+0000 E QUERY [thread1] Error: listDatabases
failed:{
"ok" : 0,
"errmsg" : "not authorized on admin to execute command {
listDatabases: 1.0 }",
"code" : 13,
"codeName" : "Unauthorized"
} :
_getErrorWithCode@src/mongo/shell/utils.js:25:13
Mongo.prototype.getDBs@src/mongo/shell/mongo.js:62:1
shellHelper.show@src/mongo/shell/utils.js:755:19
shellHelper@src/mongo/shell/utils.js:645:15
@(shellhelp2):1:1