[SERVER-10927] if a replicaset member goes down during a $out we are left with an inconsistent state Created: 26/Sep/13  Updated: 11/Jul/16  Resolved: 07/Oct/13

Status: Closed
Project: Core Server
Component/s: Aggregation Framework
Affects Version/s: 2.5.2
Fix Version/s: 2.5.3

Type: Bug Priority: Major - P3
Reporter: Matt Dannenberg Assignee: Mathias Stearn
Resolution: Done Votes: 0
Labels: 26qa
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Related
related to SERVER-11083 replsets/temp_namespace.js failing on... Closed
Operating System: ALL
Participants:

 Description   

If you kill a server during $out you well end up in one of two bad states.

If it's the primary you kill, the secondaries are left with the tmp collections.

If it's a secondary you kill, that secondary will drop the tmp collection when it restarts and then continue building the tmp collection as it reads the primary's oplog. As a result, the entries written before the reboot are absent from the output collection once the aggregation has finished.



 Comments   
Comment by auto [ 11/Oct/13 ]

Author:

{u'username': u'RedBeard0531', u'name': u'Mathias Stearn', u'email': u'mathias@10gen.com'}

Message: SERVER-11138 Try to stabilize replsets/temp_namespace.js

Test is for SERVER-10927
Branch: master
https://github.com/mongodb/mongo/commit/e76e27acacd2e2665e741be3cb58b4071f6616a4

Comment by auto [ 10/Oct/13 ]

Author:

{u'username': u'RedBeard0531', u'name': u'Mathias Stearn', u'email': u'mathias@10gen.com'}

Message: SERVER-10927 Fix replsets/temp_namespace.js failure
Branch: master
https://github.com/mongodb/mongo/commit/f86275a74e9470a2715fe0b654ac7ee1d7f772a4

Comment by auto [ 09/Oct/13 ]

Author:

{u'username': u'RedBeard0531', u'name': u'Mathias Stearn', u'email': u'mathias@10gen.com'}

Message: SERVER-10927 Fix test to wait for replication correctly

Fixes a race condition causing some builders to fail
Branch: master
https://github.com/mongodb/mongo/commit/c4c2ae9662f84912b6f1d7e54b929c4609c5b2dc

Comment by auto [ 07/Oct/13 ]

Author:

{u'username': u'RedBeard0531', u'name': u'Mathias Stearn', u'email': u'mathias@10gen.com'}

Message: SERVER-10927 RS hosts drop temp collections on promotion to master

Non-replicated hosts still drop temp collections on startup. This is
inappropriate for replica set members (and pure slaves) since it can lead to
discrepancies between hosts.
Branch: master
https://github.com/mongodb/mongo/commit/d119fc2d92ce0ffb4e42a117872ec8e3b6dff15a

Generated at Thu Feb 08 03:24:25 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.