-
Type: Bug
-
Resolution: Duplicate
-
Priority: Major - P3
-
None
-
Affects Version/s: 2.2.4, 2.4.1
-
Component/s: Concurrency
-
None
-
ALL
When locking and unlocking from the shell a large number of times, a state can be reached where the shell will hang for every db.fsyncUnlock(). This causes the a situation where the user is unable to unlock.
For example, the following oneliner will eventually cause the shell to hang:
for(x=0;x<100;x++){print(x);printjson(db.fsyncLock());printjson(db.fsyncLock());printjson(db.fsyncUnlock());printjson(db.fsyncUnlock());}
Appears to happen where multiple fsyncLock calls are made (rather than a corresponding fsyncUnlock for every fsyncLock. Anecdotally appears to happen when the locks count would be "zero" (all locks finished), after locking and unlocking several times.
Once the shell hangs once, no db.fsyncUnlock() will succeed - they will all cause the shell to hang, and nothing untoward will be printed in the logs (even at verbosity 5)
- duplicates
-
SERVER-6302 Race condition when multiple fsyncLock() invocations made on a mongod instance.
- Closed