[SERVER-33334] Invalid replset config is accepted by primary but rejected by secondary Created: 14/Feb/18  Updated: 06/Dec/22  Resolved: 22/Jan/19

Status: Closed
Project: Core Server
Component/s: Replication
Affects Version/s: 3.4.1
Fix Version/s: None

Type: Improvement Priority: Minor - P4
Reporter: Joe Caswell Assignee: Backlog - Replication Team
Resolution: Won't Fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Assigned Teams:
Replication
Participants:

 Description   

When adding members to a replica set the member being added is checked against the existing members for string equality, but not resolved IP.

If a member is inadvertently added with a hostname:port that differs from the existing members but resolves to the same IP:port as one of them, the primary will accept the configuration, but the duplicate host will reject it and stop participating in the replica set.

In a small replica set, this can cause the primary to step down, in which case rs.remove cannot be used to remove the erroneous entry.

If this can be changed to also resolve the hostname and compare IP:port to ensure no members are duplicated, this issue would be prevented.



 Comments   
Comment by Gregory McKeon (Inactive) [ 06/Mar/18 ]

We believe that using rs.reconfig() with

{force: true}

set will allow removing the erroneous entry. Feel free to comment on this ticket if that workaround does not suffice.

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