[SERVER-43938] Make auth_sharding_cmd_metadata.js start shards as replica sets Created: 10/Oct/19  Updated: 29/Oct/23  Resolved: 26/Jun/20

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: None
Fix Version/s: 4.4.1, 4.7.0

Type: Task Priority: Major - P3
Reporter: Cheahuychou Mao Assignee: Tommaso Tocci
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Backwards Compatibility: Fully Compatible
Backport Requested:
v4.4
Sprint: Sharding 2020-06-29
Participants:

 Description   

When starting shards as replica sets, this test fails to create user on the shard. The solution is to use st.rs0.getPrimary() instead of st.shard0. However, we want to investigate why doing this fixes the auth issue.

Also, when starting shards as replica sets, we need to log user "internal" out by doing st.s.getDB('admin').logout(); before st.stop(). Otherwise, the test will hang when ReplSetTest keeps trying to run isMaster against the admin db and failing with "too many users are authenticated".



 Comments   
Comment by Githook User [ 18/Aug/20 ]

Author:

{'name': 'Tommaso Tocci', 'email': 'tommaso.tocci@mongodb.com', 'username': 'toto-dev'}

Message: SERVER-43938 Make auth_sharding_cmd_metadata.js start shards as replica sets

(cherry picked from commit d71c2c6a619347303a272e0dc89af28faa71baf5)
Branch: v4.4
https://github.com/mongodb/mongo/commit/f945fe9aff545bd3f5e64519ec33b9ff80412cd1

Comment by Githook User [ 26/Jun/20 ]

Author:

{'name': 'Tommaso Tocci', 'email': 'tommaso.tocci@mongodb.com', 'username': 'toto-dev'}

Message: SERVER-43938 Make auth_sharding_cmd_metadata.js start shards as replica sets
Branch: master
https://github.com/mongodb/mongo/commit/d71c2c6a619347303a272e0dc89af28faa71baf5

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