[SERVER-13295] Test auth_no_pri.js uses insufficient write concern during setup. Created: 20/Mar/14  Updated: 11/Jul/16  Resolved: 20/Mar/14

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: 2.6.0-rc1
Fix Version/s: 2.6.0-rc2

Type: Bug Priority: Major - P3
Reporter: Andy Schwerin Assignee: Andy Schwerin
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
Operating System: ALL
Participants:
Linked BF Score: 0

 Description   

The test jstests/replsets/auth_no_pri.js attempts to confirm that authentication is possible on connections to replica sets with no primary. It does so by creating a small replica set, adding a user and a data document, then taking down two of the three member nodes. The remaining node must eventually drop to secondary state, at which point the test attempts to authenticate and read the data document.

Unfortunately, the test does not express sufficient write concern when inserting the user and data documents, so it is possible for either of them to fail to propagate to the last node before the first two nodes are taken down.



 Comments   
Comment by Githook User [ 20/Mar/14 ]

Author:

{u'username': u'andy10gen', u'name': u'Andy Schwerin', u'email': u'schwerin@mongodb.com'}

Message: SERVER-13295 Ensure that user and data documents reach all nodes in auth_no_pri.js.

In order to confirm that you can authenticate to and read data from a
non-primary node with auth enabled, the test set up phase must write some data
and wait for it to reach all nodes, before taking down the majority of them.
This patch achieves this by setting an appropriate write concern on the user and
data document inserts.

(cherry picked from commit 7001e916bd78097b34812c263274eaeb5fd712cf)
Branch: v2.6
https://github.com/mongodb/mongo/commit/6b5e42ed2fb2c2f246eeaa13c85a2f7118402aa4

Comment by Githook User [ 20/Mar/14 ]

Author:

{u'username': u'andy10gen', u'name': u'Andy Schwerin', u'email': u'schwerin@mongodb.com'}

Message: SERVER-13295 Ensure that user and data documents reach all nodes in auth_no_pri.js.

In order to confirm that you can authenticate to and read data from a
non-primary node with auth enabled, the test set up phase must write some data
and wait for it to reach all nodes, before taking down the majority of them.
This patch achieves this by setting an appropriate write concern on the user and
data document inserts.
Branch: master
https://github.com/mongodb/mongo/commit/7001e916bd78097b34812c263274eaeb5fd712cf

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