[SERVER-3693] mongod won't become primary if it's fsync locked Created: 25/Aug/11 Updated: 15/Feb/13 Resolved: 18/Sep/12 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Replication |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Minor - P4 |
| Reporter: | Spencer Brody (Inactive) | Assignee: | Spencer Brody (Inactive) |
| Resolution: | Done | Votes: | 0 |
| Labels: | replication | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Operating System: | ALL | ||||||||
| Participants: | |||||||||
| Description |
|
If a secondary is fsync locked, and the primary goes down, that secondary can't become primary until it is unlocked. If all secondaries are locked, this can lead you to be without a primary. |
| Comments |
| Comment by Dwight Merriman [ 04/Feb/12 ] |
|
yes that behavior is correct but does voting require a lock? even a read lock would be problematic in the current version as a write acquisition can stop everything (that is being fixed). reopening until confirmed it doesn't. a one-liner test would be assert( !dbMutex.isLocked() ) at the line where we vote |
| Comment by Eliot Horowitz (Inactive) [ 25/Aug/11 ] |
|
That seems like completely correct behavior to me. |
| Comment by Spencer Brody (Inactive) [ 25/Aug/11 ] |
|
This might actually be the desired behavior, at least as long as trying to write to locked server blocks reads ( The only case I can think of where you would want a locked secondary to become primary is if you're doing reads without slaveOk, and no writes. |