Open ShaneHarvey opened 10 months ago
We already create the user with the correct write concern:
# Explicitly set write concern to number of data-bearing members.
# If we add a user later, we need to guarantee that every node
# has the user before we authenticate ('majority' is insufficient).
self._write_concern = len(
[m for m in members
if not m.get('rsParams', {}).get('arbiterOnly')]
)
This error can happen when an existing cluster is running on port X and we try to start a new cluster on the same port.
Flaky auth failure on cluster setup:
https://spruce.mongodb.com/task/mongo_python_driver_tests_python_version_rhel8_test_ssl__platform~rhel8_auth_ssl~auth_ssl_python_version~3.7_coverage~coverage_test_4.2_replica_set_8422edf3abced2b9492123bf72ac91ab3586a69d_23_12_07_21_46_46/logs?execution=0
Perhaps the user was rolled back in the restart process? We should double check that we are using write concern majority when adding users.