<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 04:04:26 UTC 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>MongoDB Jira</title>
    <link>https://jira.mongodb.org</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>9.7.1</version>
        <build-number>970001</build-number>
        <build-date>13-04-2023</build-date>
    </build-info>


<item>
            <title>[SERVER-23773] Replica set primary unexpectedly steps down for lower priority secondary </title>
                <link>https://jira.mongodb.org/browse/SERVER-23773</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;The replica set&apos;s lower priority secondary that had network issues suddenly elects itself(even though oplog is 10min old), causing primary to step down for no apparent reason,&lt;br/&gt;
Main higher priority node then gets re-elected as primary a few seconds later. &lt;/p&gt;

&lt;p&gt;This issue triggered a rollback once the main node received primary, causing data loss at a critical moment.&lt;/p&gt;

&lt;p&gt;The setup is 2 replicas (one with priority 1 and the other 0.5) and an arbiter node.&lt;/p&gt;

&lt;p&gt;It appears that the arbiter voted for the older secondary even though it is in the same local network as the higher priority node, arbiter show this line in the log: &lt;/p&gt;
&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;2016-04-14T14:14:13.544+0000 I ASIO     [ReplicationExecutor] dropping unhealthy pooled connection to 3.3.153.248:27017&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;2016-04-14T14:14:13.544+0000 I ASIO     [ReplicationExecutor] after drop, pool was empty, going to spawn some connections&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;

&lt;p&gt;build information:&lt;/p&gt;
&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;{ &quot;version&quot; : &quot;3.2.1&quot;, &quot;gitVersion&quot; : &quot;a14d55980c2cdc565d4704a7e3ad37e4e535c1b2&quot;, &quot;modules&quot; : [  ], &quot;allocator&quot; : &quot;tcmalloc&quot;, &quot;javascriptEngine&quot; : &quot;mozjs&quot;, &quot;sysInfo&quot; : &quot;deprecated&quot;, &quot;versionArray&quot; : [ 3, 2, 1, 0 ], &quot;openssl&quot; : { &quot;running&quot; : &quot;OpenSSL 1.0.1k 8 Jan 2015&quot;, &quot;compiled&quot; : &quot;OpenSSL 1.0.1e 11 Feb 2013&quot; }, &quot;buildEnvironment&quot; : { &quot;distmod&quot; : &quot;debian71&quot;, &quot;distarch&quot; : &quot;x86_64&quot;, &quot;cc&quot; : &quot;/opt/mongodbtoolchain/bin/gcc: gcc (GCC) 4.8.2&quot;, &quot;ccflags&quot; : &quot;-fno-omit-frame-pointer -fPIC -fno-strict-aliasing -ggdb -pthread -Wall -Wsign-compare -Wno-unknown-pragmas -Winvalid-pch -Werror -O2 -Wno-unused-local-typedefs -Wno-unused-function -Wno-deprecated-declarations -Wno-unused-but-set-variable -Wno-missing-braces -fno-builtin-memcmp&quot;, &quot;cxx&quot; : &quot;/opt/mongodbtoolchain/bin/g++: g++ (GCC) 4.8.2&quot;, &quot;cxxflags&quot; : &quot;-Wnon-virtual-dtor -Woverloaded-virtual -std=c++11&quot;, &quot;linkflags&quot; : &quot;-fPIC -pthread -Wl,-z,now -rdynamic -fuse-ld=gold&quot;, &quot;target_arch&quot; : &quot;x86_64&quot;, &quot;target_os&quot; : &quot;linux&quot; }, &quot;bits&quot; : 64, &quot;debug&quot; : false, &quot;maxBsonObjectSize&quot; : 16777216, &quot;storageEngines&quot; : [ &quot;devnull&quot;, &quot;ephemeralForTest&quot;, &quot;mmapv1&quot;, &quot;wiredTiger&quot; ], &quot;ok&quot; : 1.0 }&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;</description>
                <environment></environment>
        <key id="280274">SERVER-23773</key>
            <summary>Replica set primary unexpectedly steps down for lower priority secondary </summary>
                <type id="1" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14703&amp;avatarType=issuetype">Bug</type>
                                            <priority id="2" iconUrl="https://jira.mongodb.org/images/icons/priorities/critical.svg">Critical - P2</priority>
                        <status id="6" iconUrl="https://jira.mongodb.org/images/icons/statuses/closed.png" description="The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.">Closed</status>
                    <statusCategory id="3" key="done" colorName="success"/>
                                    <resolution id="9">Done</resolution>
                                        <assignee username="kelsey.schubert@mongodb.com">Kelsey Schubert</assignee>
                                    <reporter username="linar-jether">Linar Savion</reporter>
                        <labels>
                    </labels>
                <created>Sun, 17 Apr 2016 07:02:19 +0000</created>
                <updated>Mon, 16 May 2016 22:29:29 +0000</updated>
                            <resolved>Mon, 16 May 2016 22:29:29 +0000</resolved>
                                    <version>3.2.1</version>
                                                    <component>Replication</component>
                                        <votes>0</votes>
                                    <watches>7</watches>
                                                                                                                <comments>
                            <comment id="1265672" author="thomas.schubert" created="Mon, 16 May 2016 22:29:29 +0000"  >&lt;p&gt;Hi &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=linar-jether&quot; class=&quot;user-hover&quot; rel=&quot;linar-jether&quot;&gt;linar-jether&lt;/a&gt;,&lt;/p&gt;

&lt;p&gt;Thank you for your patience. I have carefully examined the logs and determined that this is expected behavior. In my response I&apos;ll be referring to the nodes by their aliases in the table below&lt;/p&gt;

&lt;div class=&apos;table-wrap&apos;&gt;
&lt;table class=&apos;confluenceTable&apos;&gt;&lt;tbody&gt;
&lt;tr&gt;
&lt;th class=&apos;confluenceTh&apos;&gt;log&lt;/th&gt;
&lt;th class=&apos;confluenceTh&apos;&gt;priority&lt;/th&gt;
&lt;th class=&apos;confluenceTh&apos;&gt;alias&lt;/th&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;span class=&quot;nobr&quot;&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/attachment/118018/118018_mongodb_repl_fail_14_04_2016_prim.log&quot; title=&quot;mongodb_repl_fail_14_04_2016_prim.log attached to SERVER-23773&quot;&gt;mongodb_repl_fail_14_04_2016_prim.log&lt;sup&gt;&lt;img class=&quot;rendericon&quot; src=&quot;https://jira.mongodb.org/images/icons/link_attachment_7.gif&quot; height=&quot;7&quot; width=&quot;7&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/&gt;&lt;/sup&gt;&lt;/a&gt;&lt;/span&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;1&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Node1&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;span class=&quot;nobr&quot;&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/attachment/118017/118017_mongodb_repl_fail_14_04_2016.log&quot; title=&quot;mongodb_repl_fail_14_04_2016.log attached to SERVER-23773&quot;&gt;mongodb_repl_fail_14_04_2016.log&lt;sup&gt;&lt;img class=&quot;rendericon&quot; src=&quot;https://jira.mongodb.org/images/icons/link_attachment_7.gif&quot; height=&quot;7&quot; width=&quot;7&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/&gt;&lt;/sup&gt;&lt;/a&gt;&lt;/span&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;0.5&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Node2&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;&lt;span class=&quot;nobr&quot;&gt;&lt;a href=&quot;https://jira.mongodb.org/secure/attachment/118016/118016_mongodb_repl_fail_14_04_2016_arb.log&quot; title=&quot;mongodb_repl_fail_14_04_2016_arb.log attached to SERVER-23773&quot;&gt;mongodb_repl_fail_14_04_2016_arb.log&lt;sup&gt;&lt;img class=&quot;rendericon&quot; src=&quot;https://jira.mongodb.org/images/icons/link_attachment_7.gif&quot; height=&quot;7&quot; width=&quot;7&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/&gt;&lt;/sup&gt;&lt;/a&gt;&lt;/span&gt;&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;arb&lt;/td&gt;
&lt;td class=&apos;confluenceTd&apos;&gt;Arbiter&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;
&lt;/div&gt;


&lt;p&gt;I&apos;ll describe the election that occurs at 2016-04-14T14:18:52 since it has the most surrounding context. Other elections appear to have the same root cause. &lt;/p&gt;

&lt;p&gt;Due to network issues, Node2 successfully connects to the Arbiter, but not Node1. Consequently, when the Arbiter has to drop its pooled connection to Node1, Node2 starts an election since it has not seen a primary (Node1) for over 10 seconds. Since neither Node2 nor the Arbiter are currently connected Node1, Node2 wins the election. Eventually, Node1 is able to connect to Node2 and schedules a priority takeover.&lt;/p&gt;

&lt;p&gt;All members of a replica set must be able to &lt;a href=&quot;https://docs.mongodb.com/manual/tutorial/troubleshoot-replica-sets/#test-connections-between-all-members&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;connect&lt;/a&gt; to every other member of the set to support replication. Since this condition was not met, the failover occurred. Unfortunately, since MongoDB cannot predict these network conditions, it must always follow its &lt;a href=&quot;https://docs.mongodb.com/manual/core/replication-introduction/#automatic-failover&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;replication protocol&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;For MongoDB-related support discussion please post on the &lt;a href=&quot;http://groups.google.com/group/mongodb-user&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;mongodb-users group&lt;/a&gt; or &lt;a href=&quot;http://stackoverflow.com/questions/tagged/mongodb&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;Stack Overflow with the &lt;tt&gt;mongodb&lt;/tt&gt; tag&lt;/a&gt;. Questions about troubleshooting network connectivity issues would involve more discussion are best posted on the mongodb-users group.&lt;/p&gt;

&lt;p&gt;Kind regards,&lt;br/&gt;
Thomas&lt;/p&gt;</comment>
                            <comment id="1237999" author="linar-jether" created="Sun, 17 Apr 2016 07:03:46 +0000"  >&lt;p&gt;May be related to the comments at the end of this issue: &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-20985&quot; title=&quot;Replica set primary unexpectedly stepping down&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-20985&quot;&gt;&lt;del&gt;SERVER-20985&lt;/del&gt;&lt;/a&gt;&lt;br/&gt;
Talking about a lower priority node being elected for a few seconds&lt;/p&gt;</comment>
                    </comments>
                    <attachments>
                            <attachment id="118017" name="mongodb_repl_fail_14_04_2016.log" size="1233109" author="linar-jether" created="Sun, 17 Apr 2016 07:02:19 +0000"/>
                            <attachment id="118016" name="mongodb_repl_fail_14_04_2016_arb.log" size="1577590" author="linar-jether" created="Sun, 17 Apr 2016 07:02:19 +0000"/>
                            <attachment id="118018" name="mongodb_repl_fail_14_04_2016_prim.log" size="1780046" author="linar-jether" created="Sun, 17 Apr 2016 07:02:19 +0000"/>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                <customfield id="customfield_10050" key="com.atlassian.jira.toolkit:comments">
                        <customfieldname># Replies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Thu, 5 May 2016 20:19:10 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        7 years, 39 weeks, 2 days ago
    
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_18254" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Dependencies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue><![CDATA[]]></customfieldvalue>


                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_15850" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_10057" key="com.atlassian.jira.toolkit:lastusercommented">
                        <customfieldname>Last comment by Customer</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>true</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_10056" key="com.atlassian.jira.toolkit:lastupdaterorcommenter">
                        <customfieldname>Last commenter</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>kelsey.schubert@mongodb.com</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_11151" key="com.atlassian.jira.toolkit:LastCommentDate">
                        <customfieldname>Last public comment date</customfieldname>
                        <customfieldvalues>
                            7 years, 39 weeks, 2 days ago
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                    <customfield id="customfield_10032" key="com.atlassian.jira.plugin.system.customfieldtypes:select">
                        <customfieldname>Operating System</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="10026"><![CDATA[ALL]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_10051" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>kelsey.schubert@mongodb.com</customfieldvalue>
            <customfieldvalue>linar-jether</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hrka4f:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hskhz3:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10558" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>9223372036854775807</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_10053" key="com.atlassian.jira.ext.charting:timeinstatus">
                        <customfieldname>Time In Status</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                        <customfield id="customfield_22870" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Triagers</customfieldname>
                        <customfieldvalues>
                                    <customfieldvalue><![CDATA[kelsey.schubert@mongodb.com]]></customfieldvalue>
    

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_14350" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>serverRank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hrkwev:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                    </customfields>
    </item>
</channel>
</rss>