-
Type:
Question
-
Resolution: Done
-
Priority:
Minor - P4
-
None
-
Affects Version/s: 2.2.3
-
Component/s: Querying
-
None
-
Environment:debian squeeze 6.0.3
-
None
-
3
-
None
-
None
-
None
-
None
-
None
-
None
After upgrading from Mongo 2.0.7 to Mongo 2.2.3 we started experiencing a 6,500% increase in slow logs and we went from under 5% locking to over 20% locking on the entire instance.
We suspect that the root cause is that Mongo 2.2.3 collects and reports more statistics than 2.0.7 and as a result these locking issues have now become visible whereas in 2.0.7 they were also happening but not being reported.
The majority of slow queries reported are updates to documents by object_id. We also have a legacy process that is reading the oplog in order to extract changes and push them into mysql. The constant processing of the oplog creates read locks on the oplog which in turn causes updates in the database to wait on the locks intermittently.
Does this theory sound plausible that we always had this issue but now it has become visible as a result of the upgrade?
Sanitized version of typical slow log entry.
Tue Apr 2 19:59:58 [conn313] update db.Collection query:
{ _id: "sanitized" }update: { $set:
{ sanitized_data: BinData, sanitized_time: new Date(1364957998272) }} nscanned:0 nupdated:1 fastmodinsert:1 keyUpdates:0 locks(micros) w:390138 390ms