Authentication fails
See original GitHub issueI’m trying to connect to a database on my localhost. I can connect just fine from the command line, but when I try with the WebStorm plugin it’s not working. I enter the credentials and information like so: When I press “Test Connection” it says it’s successful. But when I save the configuration and try to connect to the database my IDE hangs for 30 seconds and I get this error:
8:54:42 PM MongoTimeoutException: Error when collecting Mongo databases: Timed out after 30000 ms while waiting for a server that matches ReadPreferenceServerSelector{readPreference=primary}. Client view of cluster state is {type=UNKNOWN, servers=[{address=localhost:27017, type=UNKNOWN, state=CONNECTING, exception={com.mongodb.MongoSecurityException: Exception authenticating}, caused by {com.mongodb.MongoCommandException: Command failed with error 18: 'auth failed' on server localhost:27017. The full response is { "ok" : 0.0, "errmsg" : "auth failed", "code" : 18 }}}]
Not sure why auth failed
, I definitely have the right credentials. Any help?
Issue Analytics
- State:
- Created 8 years ago
- Comments:15 (5 by maintainers)
Top Results From Across the Web
Authentication Fails - an overview | ScienceDirect Topics
If user authentication fails (for any reason) the user will be prompted for credentials. ... In all of these cases authentication will fail...
Read more >I get a message that says “Authentication failed”
This kind of error happens when your instant messaging service is not allowing you to connect because it does not recognize your username...
Read more >"Authentication failed" error when you try to log on to Unified ...
Fixes a problem in which you receive an "Authentication failed" error message when you use the UPN format to log on to a...
Read more >Authentication Failed - The Error Explained
When attempting to send an email, your email program may report an "Authentication Failed" error message. Authentication is the act of providing a...
Read more >AUTHENTICATION-FAILED( ) method
Indicates that the identity asserted in the unsealed client-principal object cannot be authenticated. This authentication failure signifies that the ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
The problem is the new authentication mechanism from mongoDB 3. MongoDB use now
SCRAM-SHA-1
and no longerMONGODB-CR
.After I changed the authentication mechanism back to
MONGODB-CR
in my mongoDB the plugin works perfect.Changed in version 3.0.
MongoDB supports multiple authentication mechanisms. MongoDB’s default authentication method is a challenge and response mechanism (SCRAM-SHA-1). Previously, MongoDB used MongoDB Challenge and Response (MONGODB-CR) as the default.
http://docs.mongodb.org/manual/core/authentication
The SNAPSHOT version fixed the issue for me. Thanks!