Replica set members not resyncing after primary goes down
<p>I have a replica set with 3 nodes, I have a server titled dev-6 which is running mongo 3.0.6, and dev 5 which has 2 mongos on it running 3.2. I'd like for dev 6 to be the that is the primary, and so I've added the other 2 nodes to its initiated replica set, once I do that it becomes primary and the other 2 nodes begin to sync to it. Here is a screenshot of how my setup looks like when I bring down dev 6, and then is brought back up.</p>
<p><a href="https://i.stack.imgur.com/BZ8ng.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/BZ8ng.png" alt="enter image description here" /></a></p>
<p>As, intended dev 6 is secondary, and so is dev 5: 27018. What I'm wondering about though is why is dev 5 saying there's no one to sync with, but dev 5:27019 is saying that its syncing with dev 5 :27018.</p>
<p>Im now going to follow the <a href="https://docs.mongodb.com/v3.2/tutorial/force-member-to-be-primary/" rel="nofollow noreferrer">mongo</a> instructions to make dev 6 the primary, here is the result now.</p>
<p><a href="https://i.stack.imgur.com/KOwTR.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/KOwTR.png" alt="enter image description here" /></a></p>
<p>Dev 6 is the primary, but what Im trying to understand is how come the other dev 5 instances are not connecting with dev 6. Before some conclusions are jumped to, I am able to ping dev 5 from dev 6 and visa versa, the <code>/etc/hosts</code> profiles contain the ip addresses for one another.</p>
<p><strong>EDIT:</strong> Im basing the replica set being unable to connect with the following message <code>&quot;lastHeartbeatMessage&quot; : &quot;could not find member to sync from&quot;,</code>. This seems to be fixed if I run <code>rs.config(//current cfg)</code> or if I add or remove a replica set.</p>