[SERVER-5895] auth.js times out waiting for user authentication to replicate Created: 22/May/12 Updated: 11/Jul/16 Resolved: 22/May/12 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Replication, Security |
| Affects Version/s: | None |
| Fix Version/s: | 2.1.2 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Ian Whalen (Inactive) | Assignee: | Greg Studer |
| Resolution: | Done | Votes: | 0 |
| Labels: | buildbot | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Operating System: | ALL | ||||||||
| Participants: | |||||||||
| Description |
http://buildlogs.mongodb.org/build/4fbb160bd2a60f22cc000bb7/test/4fbb35e7d2a60f3e8e0003ff/ |
| Comments |
| Comment by Blake Niemyjski [ 13/Mar/14 ] |
|
I just had this same error happen to me on centos using 2.4.9 |
| Comment by Spencer Brody (Inactive) [ 07/Feb/13 ] |
|
aleksey@myinvisible.net, that is because addUser uses getLastError with "w":"majority" by default to verify the write propagated to a majority of secondaries, and master-slave replication doesn't support "w":"majority". You can get around this by providing a number value to use for the "w" argument to getLastError. When calling addUser, the first argument is username, second is password, third is whether or not the user should be read-only, and fourth is how many servers to wait for the user to replicate to. If you explicitly provide a number value for how many slaves you want to wait for, you'll override the default of "majority" that always times out in 2.2. |
| Comment by Aleksey Mykhailov [ 05/Feb/13 ] |
|
getting the same error message on the master-slave installation db version v2.2.3, pdfile version 4.5 > db.addUser('test','test') Tue Feb 5 13:52:16 uncaught exception: timed out while waiting for user authentication to replicate - database will not be fully secured until replication finishes |
| Comment by Greg Studer [ 22/May/12 ] |
|
Think this should fix - but there may be other places the same problem manifests. |
| Comment by auto [ 22/May/12 ] |
|
Author: {u'login': u'gregstuder', u'name': u'Greg Studer', u'email': u'greg@10gen.com'}Message: wait for secondary status before addUser so we're more sure the change propagates |