Robomongo not connected to MongoDB permissions issue

Source: Internet
Author: User
Tags mongodb robomongo

using Robomongo to connect MongoDB 3.x Authorization failed solution Recently installed mongodb3.1.4, and enabled authorization authentication, in DOS window operation without any problems, in order to maintain the convenience of downloading a client tool Robomongo 0.8.5, user name, password, such as configuration good solution test, the result of connection service is not a problem, permission verification did not pass , as shown in the log, found a sentence: Failed to authenticate admin@admin with mechanism mongodb-cr:authenticationfailed MONGODB-CR credentials Missing in the user document tried all kinds of ways, 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 solution: In the non-authorization state first, delete the useful Second, modify the CurrentVersion of the version table, after which the user is re-created
Operation steps: 1, delete User: Db.dropuser ("admin"), 2, modify Version:db.system.version.update ({"_id": "Authschema"},{$set: {" CurrentVersion ": 3}}); 3. Re-create the user:
 

Db.createuser ({User: "admin", pwd: "admin", roles:[{"role": "Useradminanydatabase", "db": "admin"},{"role": "ReadWrite "," DB ":" Test "}]}) 4, restart the MONGDB service, test again, finish the work.
Transferred from: http://liyanjie918.blog.163.com/blog/static/2022729020156261410274/

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.