Recently installed the mongodb3.0, and enabled the authorization authentication, the DOS window operation without any problems, as shown in figure:
In order to maintain the convenience of downloading a client tool Robomongo 0.8.4, user name, password, such as configuration better solution test,
As a result, the connection service does not have a problem, and permission validation does not pass, as shown:
View the log, found a sentence: Failed to authenticate admin@admin with mechanism mongodb-cr:authenticationfailed MONGODB-CR credentials Missing in the user document, tried a variety of methods, Baidu Search all over no one can solve, no way can only ask Google, finally in a foreign site found original or MongoDB database version problem, query version as shown:
Solution: 1, delete User: Db.dropuser ("admin"), 2, modify Version:db.system.version.update ({"_id": "Authschema"},{$set: {" CurrentVersion ": 3}}); 3. Re-create User: Db.createuser ({User:" admin ", pwd:" admin ", roles:[{" role ":" Useradminanydatabase "," DB ":" admin "},{" role ":" ReadWrite "," DB ":" Test "}]})
Restart the MONGDB service, test again, Robomongo Connect as shown: