<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Wed Feb 07 21:39:12 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>[CSHARP-1295] Requiring all seed processes to be working in initial connection defeats the purpose of HA of a replication set</title>
                <link>https://jira.mongodb.org/browse/CSHARP-1295</link>
                <project id="10041" key="CSHARP">C# Driver</project>
                    <description>&lt;h3&gt;&lt;a name=&quot;Problem%3A&quot;&gt;&lt;/a&gt;Problem:&lt;/h3&gt;
&lt;p&gt;In initial connection, if one of the seed mongo processes is down, the connection won&apos;t be established.  a machine/process can be down for a long time, this means no new connection can be established during this time, this defeats the purpose of High Availability of a replication set.&lt;/p&gt;

&lt;h3&gt;&lt;a name=&quot;ExpectedResult%3A&quot;&gt;&lt;/a&gt;Expected Result:&lt;/h3&gt;
&lt;p&gt;As long as one of the seed process is working, connection should be established.&lt;/p&gt;

&lt;h3&gt;&lt;a name=&quot;Note%3A&quot;&gt;&lt;/a&gt;Note:&lt;/h3&gt;
&lt;p&gt;Not repro in NodeJS driver. so it&apos;s C# driver&apos;s issue.&lt;/p&gt;

&lt;h3&gt;&lt;a name=&quot;Error%3A&quot;&gt;&lt;/a&gt;Error:&lt;/h3&gt;
&lt;p&gt;   at MongoDB.Driver.Core.Servers.ClusterableServer.&amp;lt;HeartbeatAsync&amp;gt;d__d.MoveNext()&quot; }, { ServerId: &quot;&lt;/p&gt;
{ ClusterId : 1, EndPoint : &quot;Unspecified/vmpri0521e.westus.cloudapp.azure.com:27000&quot; }
&lt;p&gt;&quot;, EndPoint: &quot;Unspecified/vmpri0521e.westus.cloudapp.azure.com:27000&quot;, State: &quot;Disconnected&quot;, Type: &quot;Unknown&quot;, HeartbeatException: &quot;MongoDB.Driver.MongoConnectionException: An exception occurred while opening a connection to the server. ---&amp;gt; System.Net.Sockets.SocketException: No connection could be made because the target machine actively refused it 191.236.92.13:27000&lt;/p&gt;</description>
                <environment></environment>
        <key id="206134">CSHARP-1295</key>
            <summary>Requiring all seed processes to be working in initial connection defeats the purpose of HA of a replication set</summary>
                <type id="1" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14703&amp;avatarType=issuetype">Bug</type>
                                            <priority id="1" iconUrl="https://jira.mongodb.org/images/icons/priorities/blocker.svg">Blocker - P1</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="craig.wilson@mongodb.com">Craig Wilson</assignee>
                                    <reporter username="tryshi">tryshi</reporter>
                        <labels>
                    </labels>
                <created>Fri, 22 May 2015 21:40:06 +0000</created>
                <updated>Thu, 28 May 2015 01:36:57 +0000</updated>
                            <resolved>Wed, 27 May 2015 16:18:13 +0000</resolved>
                                    <version>2.0</version>
                                                    <component>Connectivity</component>
                                        <votes>0</votes>
                                    <watches>1</watches>
                                                                                                                <comments>
                            <comment id="924807" author="craiggwilson" created="Wed, 27 May 2015 16:18:13 +0000"  >&lt;p&gt;Great.&lt;/p&gt;

&lt;p&gt;I&apos;m going to close this as Works as Designed. As we discuss internally what to do regarding whitespace, I&apos;ll link back to this ticket with a new one if we are going to do that. &lt;/p&gt;

&lt;p&gt;Thanks for your persistence. I know this took a little while. Feel free to delete some of the comments if you wish the public not to have access to your instances.&lt;br/&gt;
Craig&lt;/p&gt;</comment>
                            <comment id="924802" author="tryshi" created="Wed, 27 May 2015 16:15:54 +0000"  >&lt;p&gt;You&apos;re absolutely right, after removing the extra space, everything works beautifully, bad dns in seed and killing primary won&apos;t affect the availability. &lt;br/&gt;
Thanks a million!&lt;/p&gt;

&lt;p&gt;From MongoDB manual ( &lt;a href=&quot;http://docs.mongodb.org/manual/reference/connection-string/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://docs.mongodb.org/manual/reference/connection-string/&lt;/a&gt; ), the format does not have space. But as a programmer, I sometimes add extra space here and there for readability. so it will be great we either fix the driver or make it clear in the manual that extra space is not allowed.&lt;/p&gt;

&lt;p&gt;Again, thank a lot for your time and effort. Mongodb does provide excellent user experience and support, I really love it!&lt;/p&gt;</comment>
                            <comment id="924769" author="craiggwilson" created="Wed, 27 May 2015 15:49:21 +0000"  >&lt;p&gt;Hi &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=tryshi&quot; class=&quot;user-hover&quot; rel=&quot;tryshi&quot;&gt;tryshi&lt;/a&gt;,&lt;/p&gt;

&lt;p&gt;Thank you so much for providing access. It made this go much faster.&lt;/p&gt;

&lt;p&gt;And good news! I&apos;ve figured out the problem. In your connection string, your second host has a space before it just after the comma. So, &lt;tt&gt;mongodb://badhost, goodhost&lt;/tt&gt; doesn&apos;t work because it&apos;s trying to resolve the &quot;goodhost&quot; server with &quot; goodhost&quot;.  Simply removing the comma fixes the problem. Also, just to note, using &lt;tt&gt;mongodb://goodhost, badhost&lt;/tt&gt; works as well because &quot;goodhost&quot; is resolved correctly.&lt;/p&gt;

&lt;p&gt;We can see this from the socket logs:&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;System.Net.Sockets Verbose: 0 : [1324] Socket#12919499::Socket(AddressFamily#2)&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;   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;System.Net.Sockets Verbose: 0 : [1324] Exiting Socket#12919499::Socket() &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;   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;System.Net.Sockets Verbose: 0 : [1324] Socket#12919499::BeginConnect( vmsec0521e.westus.cloudapp.azure.com)&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;   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;System.Net.Sockets Verbose: 0 : [1324] DNS::UnsafeBeginGetHostAddresses( vmsec0521e.westus.cloudapp.azure.com)&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;   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;System.Net.Sockets Verbose: 0 : [1324] Exiting DNS::UnsafeBeginGetHostAddresses() 	-&amp;gt; ResolveAsyncResult#49891972&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;   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;System.Net.Sockets Verbose: 0 : [5260] DNS::GetHostByName( vmsec0521e.westus.cloudapp.azure.com)&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;   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;System.Net.Sockets Verbose: 0 : [1324] Exiting Socket#12919499::BeginConnect() 	-&amp;gt; MultipleAddressConnectAsyncResult#23511423&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;   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;System.Net.Sockets Verbose: 0 : [5260] DNS::EndGetHostAddresses(ResolveAsyncResult#49891972)&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;   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;System.Net.Sockets Verbose: 0 : [4376] Socket#12919499::EndConnect(MultipleAddressConnectAsyncResult#23511423)&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;   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;System.Net.Sockets Error: 0 : [4376] Exception in Socket#12919499::EndConnect - No such host is known.&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;   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;   at System.Net.Dns.HostResolutionEndHelper(IAsyncResult asyncResult)&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;   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;   at System.Net.Dns.EndGetHostAddresses(IAsyncResult asyncResult)&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;   at System.Net.Sockets.Socket.DnsCallback(IAsyncResult result)&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;As well as our own logs:&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;2015-05-27 14:35:17.2377021Z Info  1   1: added server  vmsec0521e.westus.cloudapp.azure.com:37000 in 0.7116ms.&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;   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;2015-05-27 14:35:17.2396908Z Info  1   1: { ClusterId : &quot;1&quot;, Type : &quot;ReplicaSet&quot;, State : &quot;Disconnected&quot;, Servers : [{ ServerId: &quot;{ ClusterId : 1, EndPoint : &quot;Unspecified/ vmsec0521e.westus.cloudapp.azure.com:37000&quot; }&quot;, EndPoint: &quot;Unspecified/ vmsec0521e.westus.cloudapp.azure.com:37000&quot;, State: &quot;Disconnected&quot;, Type: &quot;Unknown&quot; }, { ServerId: &quot;{ ClusterId : 1, EndPoint : &quot;Unspecified/vmpri0521e-wrong-dns.westus.cloudapp.azure.com:37000&quot; }&quot;, EndPoint: &quot;Unspecified/vmpri0521e-wrong-dns.westus.cloudapp.azure.com:37000&quot;, State: &quot;Disconnected&quot;, Type: &quot;Unknown&quot; }] }&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;   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;2015-05-27 14:35:17.2426911Z Error 8   1: vmsec0521e.westus.cloudapp.azure.com:37000:2: unable to open. Exception: MongoDB.Driver.MongoConnectionException: An exception occurred while opening a connection to the server. ---&amp;gt; System.Net.Sockets.SocketException: No such host is known&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;   at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)&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;I am currently chatting with our other driver engineers and spec authors to determine whether or not we should be stripping whitespace. Apparently some do and some don&apos;t. If we decide to do that, I&apos;ll open another ticket specifically for it.&lt;/p&gt;

&lt;p&gt;For now, could you confirm that this fixes your problems?&lt;br/&gt;
Craig&lt;/p&gt;</comment>
                            <comment id="924716" author="tryshi" created="Wed, 27 May 2015 15:23:17 +0000"  >&lt;p&gt;The repro needs below workaround with hosts file in C:\Windows\System32\drivers\etc&lt;/p&gt;

&lt;p&gt;#Db IP host mapping&lt;br/&gt;
191.236.92.13  vmpri0521e&lt;br/&gt;
191.236.81.200 vmsec0521e&lt;br/&gt;
191.239.49.7   vmarb0521e&lt;/p&gt;
</comment>
                            <comment id="924707" author="tryshi" created="Wed, 27 May 2015 15:21:01 +0000"  >&lt;p&gt;The logs are in the attachment.&lt;/p&gt;

&lt;p&gt;here is the code with real username/password populated, so you can easily repro it by yourself.&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;            // Good-TwoSeeds&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;   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;             var cnnString = &quot;mongodb://&amp;lt;userName:&amp;lt;userPassword&amp;gt;@vmpri0521e.westus.cloudapp.azure.com:27000, vmsec0521e.westus.cloudapp.azure.com:27000/testdb?replicaSet=rs0521e&quot;;&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;   width: auto; padding: 0;&quot;&gt;&amp;nbsp;&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;   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;            // Good-SingleSeed&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;   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;            // var cnnString = &quot;mongodb://&amp;lt;userName&amp;gt;:&amp;lt;userPassword&amp;gt;@vmsec0521e.westus.cloudapp.azure.com:27000/testdb?replicaSet=rs0521e&quot;;&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;   width: auto; padding: 0;&quot;&gt;&amp;nbsp;&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;   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;            // Bad-TwoSeeds-With-wrong-dns&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;   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;            //var cnnString = &quot;mongodb://&amp;lt;userName&amp;gt;:&amp;lt;password&amp;gt;@vmpri0521e-wrong-dns.westus.cloudapp.azure.com:27000, vmsec0521e.westus.cloudapp.azure.com:37000/testdb?replicaSet=rs0521e&quot;;&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;   width: auto; padding: 0;&quot;&gt;&amp;nbsp;&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;   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;            var settings = MongoClientSettings.FromUrl(new MongoUrl(cnnString));&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;   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;            settings.ClusterConfigurator = cb =&amp;gt;&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;   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;            {&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;   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;                var textWriter = TextWriter.Synchronized(new StreamWriter(&quot;mylogfile.txt&quot;));&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;   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;                cb.AddListener(new LogListener(textWriter));&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;   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;            };&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;   width: auto; padding: 0;&quot;&gt;&amp;nbsp;&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;   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;            var client = new MongoClient(settings);&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;   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;            var db = client.GetDatabase(&quot;testdb&quot;);&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;   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;            var col = db.GetCollection&amp;lt;BsonDocument&amp;gt;(&quot;users&quot;);&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;   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;            await col.InsertOneAsync(new BsonDocument(&quot;name&quot;, &quot;jack&quot;));&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;   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;            var users = await col.Find(e =&amp;gt; true).ToListAsync();&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;   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;            foreach (var document in users)&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;   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;            {&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;   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;                Console.WriteLine(document[&quot;name&quot;]);&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;   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;            }&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;&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;</comment>
                            <comment id="924699" author="tryshi" created="Wed, 27 May 2015 15:16:20 +0000"  >&lt;p&gt;Here are the logs.&lt;/p&gt;</comment>
                            <comment id="924192" author="tryshi" created="Wed, 27 May 2015 02:19:15 +0000"  >&lt;p&gt;Thanks Craig for your time.&lt;br/&gt;
I will provide the information later tonight.&lt;/p&gt;

&lt;p&gt;tryshi.&lt;/p&gt;</comment>
                            <comment id="924186" author="craiggwilson" created="Wed, 27 May 2015 02:15:41 +0000"  >&lt;p&gt;Thanks for confirming you can connect from the shell. The driver doesn&apos;t look at priority, but that&apos;s certainly a good guess.&lt;/p&gt;

&lt;p&gt;1. Are you also able to connect from the driver when only supplying that one host? For example, using this connection string: &lt;tt&gt;mongodb://vmsec0521e.westus.cloudapp.azure.com:37000&lt;/tt&gt;.&lt;/p&gt;

&lt;p&gt;2. If not, it&apos;d be great if you could provide a .NET socket trace log as specified here: &lt;a href=&quot;https://msdn.microsoft.com/en-us/library/ty48b824%28v=vs.110%29.aspx&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://msdn.microsoft.com/en-us/library/ty48b824%28v=vs.110%29.aspx&lt;/a&gt;. In particular, I&apos;m looking for the System.Net.Sockets output.&lt;/p&gt;

&lt;p&gt;3. Also, if you&apos;re up for it, I&apos;d love to see the log when you configure tracing from the driver itself:&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;var settings = MongoClientSettings.FromUrl(new MongoUrl(connectionString));&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;   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;settings.ClusterConfigurator = cb =&amp;gt;&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;   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;{&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;   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;    var textWriter = TextWriter.Synchronized(new StreamWriter(&quot;mylogfile.txt&quot;));&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;   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;    cb.AddListener(new LogListener(textWriter));&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;   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;};&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;   width: auto; padding: 0;&quot;&gt;&amp;nbsp;&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;   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;var client = new MongoClient(settings);&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;// etc...&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;Thanks for hanging with me.&lt;br/&gt;
Craig&lt;/p&gt;</comment>
                            <comment id="924181" author="tryshi" created="Wed, 27 May 2015 02:09:34 +0000"  >&lt;p&gt;My hunch is the Priority may play a role here. .&lt;/p&gt;</comment>
                            <comment id="924178" author="tryshi" created="Wed, 27 May 2015 02:07:57 +0000"  >&lt;p&gt;I can always connect to the vmsec0512e. below is the result after failover.&lt;/p&gt;

&lt;p&gt;mongo.exe vmsec0521e.westus.cloudapp.azure.com:37000/testoc -u &amp;lt;userName&amp;gt; -p &amp;lt;passWord&amp;gt;&lt;br/&gt;
MongoDB shell version: 3.0.2&lt;br/&gt;
connecting to: vmsec0521e.westus.cloudapp.azure.com:37000/testoc&lt;br/&gt;
rs0521e:PRIMARY&amp;gt;&lt;/p&gt;</comment>
                            <comment id="924176" author="tryshi" created="Wed, 27 May 2015 02:05:51 +0000"  >&lt;p&gt;for your question:&lt;br/&gt;
&amp;gt;&amp;gt;are you able to use the mongo shell and successfully connect? &lt;br/&gt;
&amp;gt;&amp;gt;mongo --host vmsec0521e.westus.cloudapp.azure.com --port 37000&lt;/p&gt;

&lt;p&gt;Yes, I can.&lt;/p&gt;</comment>
                            <comment id="924174" author="tryshi" created="Wed, 27 May 2015 02:03:50 +0000"  >&lt;h3&gt;&lt;a name=&quot;reprobykillingmongodprocessinPrimaryvmpri0521e&quot;&gt;&lt;/a&gt;repro by killing mongod process in Primary vmpri0521e&lt;/h3&gt;
&lt;h4&gt;&lt;a name=&quot;Code%2Csameasabove%2Cexeceptconnectionstringisasthefollowing.&quot;&gt;&lt;/a&gt;Code, same as above, execept connection string is as the following.&lt;/h4&gt;
&lt;p&gt;var cnnString = &quot;mongodb://&amp;lt;userName&amp;gt;:&amp;lt;passWord&amp;gt;@vmpri0521e.westus.cloudapp.azure.com:37000, vmsec0521e.westus.cloudapp.azure.com:37000/testoc?replicaSet=rs0521e&quot;;&lt;/p&gt;

&lt;p&gt;ssh into the Primary machine vmpri0512e, kill mongod process.&lt;br/&gt;
Waited for mongodb to fail over to secondary(verified by NodeJS code and shell).&lt;br/&gt;
run the code.&lt;/p&gt;

&lt;h4&gt;&lt;a name=&quot;Exception&quot;&gt;&lt;/a&gt;Exception&lt;/h4&gt;
&lt;p&gt;Unhandled Exception: System.AggregateException: One or more errors occurred. ---&amp;gt; System.TimeoutException: A timeout occured after 30000ms selecting a server using CompositeServerSelector{ Selectors = ReadPreferenceServerSelector{ ReadPreference = &lt;/p&gt;
{ Mode = Primary, TagSets = System.Collections.Generic.List`1[MongoDB.Driver.TagSet] }
&lt;p&gt; }, LatencyLimitingServerSelector&lt;/p&gt;
{ AllowedLatencyRange = 00:00:00.0150000 }
&lt;p&gt; }. Client view of cluster state is { ClusterId : &quot;1&quot;, Type : &quot;ReplicaSet&quot;, State : &quot;Disconnected&quot;, Servers : [{ ServerId: &quot;&lt;/p&gt;
{ ClusterId : 1, EndPoint : &quot;Unspecified/ vmsec0521e.westus.cloudapp.azure.com:37000&quot; }
&lt;p&gt;&quot;, EndPoint: &quot;Unspecified/ vmsec0521e.westus.cloudapp.azure.com:37000&quot;, State: &quot;Disconnected&quot;, Type: &quot;Unknown&quot;, HeartbeatException: &quot;MongoDB.Driver.MongoConnectionException: An exception occurred while opening a connection to the server. ---&amp;gt; System.Net.Sockets.SocketException: No such host is known&lt;br/&gt;
   at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)&lt;br/&gt;
   at System.Threading.Tasks.TaskFactory`1.FromAsyncCoreLogic(IAsyncResult iar, Func`2 endFunction, Action`1 endAction, Task`1 promise, Boolean requiresSynchronization)&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.TcpStreamFactory.&amp;lt;ConnectAsync&amp;gt;d__7.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.TcpStreamFactory.&amp;lt;CreateStreamAsync&amp;gt;d__0.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.ConfiguredTaskAwaitable`1.ConfiguredTaskAwaiter.GetResult()&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.BinaryConnection.&amp;lt;OpenAsyncHelper&amp;gt;d__1.MoveNext()&lt;br/&gt;
   &amp;#8212; End of inner exception stack trace &amp;#8212;&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.BinaryConnection.&amp;lt;OpenAsyncHelper&amp;gt;d__1.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Servers.ClusterableServer.&amp;lt;HeartbeatAsync&amp;gt;d__d.MoveNext()&quot; }, { ServerId: &quot;&lt;/p&gt;
{ ClusterId : 1, EndPoint : &quot;Unspecified/vmpri0521e.westus.cloudapp.azure.com:37000&quot; }
&lt;p&gt;&quot;, EndPoint: &quot;Unspecified/vmpri0521e.westus.cloudapp.azure.com:37000&quot;, State: &quot;Disconnected&quot;, Type: &quot;Unknown&quot;, HeartbeatException: &quot;MongoDB.Driver.MongoConnectionException: An exception occurred while opening a connection to the server. ---&amp;gt; System.Net.Sockets.SocketException: No connection could be made because the target machine actively refused it 191.236.92.13:37000&lt;br/&gt;
   at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)&lt;br/&gt;
   at System.Threading.Tasks.TaskFactory`1.FromAsyncCoreLogic(IAsyncResult iar, Func`2 endFunction, Action`1 endAction, Task`1 promise, Boolean requiresSynchronization)&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.TcpStreamFactory.&amp;lt;ConnectAsync&amp;gt;d__7.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.TcpStreamFactory.&amp;lt;CreateStreamAsync&amp;gt;d__0.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.ConfiguredTaskAwaitable`1.ConfiguredTaskAwaiter.GetResult()&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.BinaryConnection.&amp;lt;OpenAsyncHelper&amp;gt;d__1.MoveNext()&lt;br/&gt;
   &amp;#8212; End of inner exception stack trace &amp;#8212;&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.BinaryConnection.&amp;lt;OpenAsyncHelper&amp;gt;d__1.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Servers.ClusterableServer.&amp;lt;HeartbeatAsync&amp;gt;d__d.MoveNext()&quot; }] }.&lt;br/&gt;
   at MongoDB.Driver.Core.Clusters.Cluster.ThrowTimeoutException(IServerSelector selector, ClusterDescription description)&lt;br/&gt;
   at MongoDB.Driver.Core.Clusters.Cluster.&amp;lt;WaitForDescriptionChangedAsync&amp;gt;d__18.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Clusters.Cluster.&amp;lt;SelectServerAsync&amp;gt;d__6.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Bindings.ReadPreferenceBinding.&amp;lt;GetReadChannelSourceAsync&amp;gt;d__0.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.ConfiguredTaskAwaitable`1.ConfiguredTaskAwaiter.GetResult()&lt;br/&gt;
   at MongoDB.Driver.Core.Operations.FindOperation`1.&amp;lt;ExecuteAsync&amp;gt;d__2.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.OperationExecutor.&amp;lt;ExecuteReadOperationAsync&amp;gt;d__0`1.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.MongoCollectionImpl`1.&amp;lt;ExecuteReadOperation&amp;gt;d__35`1.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.IAsyncCursorSourceExtensions.&amp;lt;ToListAsync&amp;gt;d__14`1.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()&lt;br/&gt;
   at mdb.Program.&amp;lt;Run&amp;gt;d__4.MoveNext() in c:\vso\ops\svcclient\mdb\cs\Program.cs:line 62&lt;br/&gt;
   &amp;#8212; End of inner exception stack trace &amp;#8212;&lt;br/&gt;
   at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken)&lt;br/&gt;
   at System.Threading.Tasks.Task.Wait()&lt;br/&gt;
   at mdb.Program.Main(String[] args) in c:\vso\ops\svcclient\mdb\cs\Program.cs:line 24&lt;/p&gt;</comment>
                            <comment id="924169" author="craiggwilson" created="Wed, 27 May 2015 01:50:09 +0000"  >&lt;p&gt;Thanks. In this particular example, it&apos;s indicating that we cannot talk to the good host either. Perhaps this is what you are reporting, but this exception ultimately comes from the .NET framework:&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;...&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;   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;EndPoint: &quot;Unspecified/ vmsec0521e.westus.cloudapp.azure.com:37000&quot;, State: &quot;Disconnected&quot;, Type: &quot;Unknown&quot;, HeartbeatException: &quot;MongoDB.Driver.MongoConnectionException: An exception occurred while opening a connection to the server. ---&amp;gt; System.Net.Sockets.SocketException: No such host is known&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;...&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;Because we can&apos;t connect to it, we aren&apos;t able to find the other ones either. Can you confirm that if you only connect to this one machine (&lt;tt&gt;mongodb://vmsec0521e.westus.cloudapp.azure.com:37000&lt;/tt&gt;), you are able to talk to it? Also, are you able to use the mongo shell and successfully connect? &lt;br/&gt;
&lt;tt&gt;mongo --host vmsec0521e.westus.cloudapp.azure.com --port 37000&lt;/tt&gt;&lt;/p&gt;

&lt;p&gt;Craig&lt;/p&gt;</comment>
                            <comment id="924166" author="tryshi" created="Wed, 27 May 2015 01:45:36 +0000"  >&lt;p&gt;I thought the scenarios is straight forward enough, so I omitted some unimportant details, but here is the full bug report.&lt;/p&gt;
&lt;h3&gt;&lt;a name=&quot;Buildareplicationsetasthefollowing&quot;&gt;&lt;/a&gt;Build a replication set as the following&lt;/h3&gt;
&lt;p&gt;machine vmpri0512e:     primary  (priority 5)&lt;br/&gt;
machine vmsec0512e:   secondary (priority 1)&lt;br/&gt;
machine vmarb0512e:   arbeiter&lt;/p&gt;
&lt;h3&gt;&lt;a name=&quot;Reprowithnonexistentdnsname.&quot;&gt;&lt;/a&gt;Repro with non existent dns name.&lt;/h3&gt;
&lt;p&gt;Put a invalid(not exist ) dns name in the seed list. Note: I&apos;ve already changed the etc/hosts file to map the private host name with IP.&lt;/p&gt;
&lt;h4&gt;&lt;a name=&quot;Code%3A&quot;&gt;&lt;/a&gt;Code:&lt;/h4&gt;
&lt;p&gt;            var myConventions = new ConventionPack();&lt;br/&gt;
            myConventions.Add(new IgnoreExtraElementsConvention(true));&lt;br/&gt;
            myConventions.Add(new IgnoreIfNullConvention(true));&lt;br/&gt;
            ConventionRegistry.Register(&quot;betterConvention&quot;, myConventions, (type) =&amp;gt; true);&lt;/p&gt;

&lt;p&gt;            var cnnString = &quot;mongodb://&amp;lt;userName&amp;gt;:&amp;lt;passWord&amp;gt;@non-existent-dns.westus.cloudapp.azure.com:37000, vmsec0521e.westus.cloudapp.azure.com:37000/testoc?replicaSet=rs0521e&quot;;&lt;br/&gt;
            var client = new MongoClient(cnnString);&lt;br/&gt;
            var db = client.GetDatabase(&quot;testoc&quot;);&lt;br/&gt;
            var col = db.GetCollection&amp;lt;BsonDocument&amp;gt;(&quot;appUsers&quot;);&lt;br/&gt;
            var users = await col.Find(e =&amp;gt; true).ToListAsync();&lt;/p&gt;

&lt;h4&gt;&lt;a name=&quot;Exception%3A&quot;&gt;&lt;/a&gt;Exception:&lt;/h4&gt;
&lt;p&gt;Unhandled Exception: System.AggregateException: One or more errors occurred. ---&amp;gt; System.TimeoutException: A timeout occured after 30000ms selecting a server using CompositeServerSelector{ Selectors = ReadPreferenceServerSelector{ ReadPreference = &lt;/p&gt;
{ Mode = Primary, TagSets = System.Collections.Generic.List`1[MongoDB.Driver.TagSet] }
&lt;p&gt; }, LatencyLimitingServerSelector&lt;/p&gt;
{ AllowedLatencyRange = 00:00:00.0150000 }
&lt;p&gt; }. Client view of cluster state is { ClusterId : &quot;1&quot;, Type : &quot;ReplicaSet&quot;, State : &quot;Disconnected&quot;, Servers : [{ ServerId: &quot;&lt;/p&gt;
{ ClusterId : 1, EndPoint : &quot;Unspecified/ vmsec0521e.westus.cloudapp.azure.com:37000&quot; }
&lt;p&gt;&quot;, EndPoint: &quot;Unspecified/ vmsec0521e.westus.cloudapp.azure.com:37000&quot;, State: &quot;Disconnected&quot;, Type: &quot;Unknown&quot;, HeartbeatException: &quot;MongoDB.Driver.MongoConnectionException: An exception occurred while opening a connection to the server. ---&amp;gt; System.Net.Sockets.SocketException: No such host is known&lt;br/&gt;
   at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)&lt;br/&gt;
   at System.Threading.Tasks.TaskFactory`1.FromAsyncCoreLogic(IAsyncResult iar, Func`2 endFunction, Action`1 endAction, Task`1 promise, Boolean requiresSynchronization)&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.TcpStreamFactory.&amp;lt;ConnectAsync&amp;gt;d__7.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.TcpStreamFactory.&amp;lt;CreateStreamAsync&amp;gt;d__0.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.ConfiguredTaskAwaitable`1.ConfiguredTaskAwaiter.GetResult()&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.BinaryConnection.&amp;lt;OpenAsyncHelper&amp;gt;d__1.MoveNext()&lt;br/&gt;
   &amp;#8212; End of inner exception stack trace &amp;#8212;&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.BinaryConnection.&amp;lt;OpenAsyncHelper&amp;gt;d__1.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Servers.ClusterableServer.&amp;lt;HeartbeatAsync&amp;gt;d__d.MoveNext()&quot; }, { ServerId: &quot;&lt;/p&gt;
{ ClusterId : 1, EndPoint : &quot;Unspecified/non-existent-dns.westus.cloudapp.azure.com:37000&quot; }
&lt;p&gt;&quot;, EndPoint: &quot;Unspecified/non-existent-dns.westus.cloudapp.azure.com:37000&quot;, State: &quot;Disconnected&quot;, Type: &quot;Unknown&quot;, HeartbeatException: &quot;MongoDB.Driver.MongoConnectionException: An exception occurred while opening a connection to the server. ---&amp;gt; System.Net.Sockets.SocketException: No such host is known&lt;br/&gt;
   at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)&lt;br/&gt;
   at System.Threading.Tasks.TaskFactory`1.FromAsyncCoreLogic(IAsyncResult iar, Func`2 endFunction, Action`1 endAction, Task`1 promise, Boolean requiresSynchronization)&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.TcpStreamFactory.&amp;lt;ConnectAsync&amp;gt;d__7.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.TcpStreamFactory.&amp;lt;CreateStreamAsync&amp;gt;d__0.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.ConfiguredTaskAwaitable`1.ConfiguredTaskAwaiter.GetResult()&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.BinaryConnection.&amp;lt;OpenAsyncHelper&amp;gt;d__1.MoveNext()&lt;br/&gt;
   &amp;#8212; End of inner exception stack trace &amp;#8212;&lt;br/&gt;
   at MongoDB.Driver.Core.Connections.BinaryConnection.&amp;lt;OpenAsyncHelper&amp;gt;d__1.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Servers.ClusterableServer.&amp;lt;HeartbeatAsync&amp;gt;d__d.MoveNext()&quot; }] }.&lt;br/&gt;
   at MongoDB.Driver.Core.Clusters.Cluster.ThrowTimeoutException(IServerSelector selector, ClusterDescription description)&lt;br/&gt;
   at MongoDB.Driver.Core.Clusters.Cluster.&amp;lt;WaitForDescriptionChangedAsync&amp;gt;d__18.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Clusters.Cluster.&amp;lt;SelectServerAsync&amp;gt;d__6.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.Core.Bindings.ReadPreferenceBinding.&amp;lt;GetReadChannelSourceAsync&amp;gt;d__0.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.ConfiguredTaskAwaitable`1.ConfiguredTaskAwaiter.GetResult()&lt;br/&gt;
   at MongoDB.Driver.Core.Operations.FindOperation`1.&amp;lt;ExecuteAsync&amp;gt;d__2.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.OperationExecutor.&amp;lt;ExecuteReadOperationAsync&amp;gt;d__0`1.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.MongoCollectionImpl`1.&amp;lt;ExecuteReadOperation&amp;gt;d__35`1.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at MongoDB.Driver.IAsyncCursorSourceExtensions.&amp;lt;ToListAsync&amp;gt;d__14`1.MoveNext()&lt;br/&gt;
&amp;#8212; End of stack trace from previous location where exception was thrown &amp;#8212;&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)&lt;br/&gt;
   at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()&lt;br/&gt;
   at mdb.Program.&amp;lt;Run&amp;gt;d__2.MoveNext() in c:\vso\ops\svcclient\mdb\cs\Program.cs:line 39&lt;br/&gt;
   &amp;#8212; End of inner exception stack trace &amp;#8212;&lt;br/&gt;
   at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken)&lt;br/&gt;
   at System.Threading.Tasks.Task.Wait()&lt;br/&gt;
 at mdb.Program.Main(String[] args) in c:\vso\ops\svcclient\mdb\cs\Program.cs:line 24&lt;/p&gt;</comment>
                            <comment id="924145" author="craiggwilson" created="Wed, 27 May 2015 00:56:13 +0000"  >&lt;p&gt;Hi tryshi,&lt;/p&gt;

&lt;p&gt;It is very difficult to understand what is going on from these repros. I am looking for something more like: 1) initiate a 3 member replica set. 2) use the connection string &quot;mongodb://...&quot;. 3) XXX&lt;/p&gt;

&lt;p&gt;Also, this does not look like the entire stack trace. Is there more that wasn&apos;t pasted in? For instance, I only see a single host in here when there is obviously 2. It would appear as though we simply can&apos;t talk to any member, which relates back to your other ticket (&lt;a href=&quot;https://jira.mongodb.org/browse/CSHARP-1294&quot; title=&quot;Fail to connect if seed name is different than host name&quot; class=&quot;issue-link&quot; data-issue-key=&quot;CSHARP-1294&quot;&gt;&lt;del&gt;CSHARP-1294&lt;/del&gt;&lt;/a&gt;). In addition, if you kill a primary when using the ReadPreference of Primary (the default), then until a new primary is elected, you won&apos;t be able to read.&lt;/p&gt;

&lt;p&gt;I&apos;m sorry this is so difficult to ascertain what is going on. Like I said, we test these scenarios extensively, so diagnosing this is going to take some time.&lt;/p&gt;

&lt;p&gt;Craig&lt;/p&gt;</comment>
                            <comment id="924135" author="tryshi" created="Wed, 27 May 2015 00:43:36 +0000"  >&lt;h3&gt;&lt;a name=&quot;Reprowithnonexistentdnsname%3A&quot;&gt;&lt;/a&gt;Repro with non existent dns name:&lt;/h3&gt;
&lt;p&gt;connection string: &quot;mongodb://&amp;lt;userName&amp;gt;:&amp;lt;passWord&amp;gt;@non-existent-dns.westus.cloudapp.azure.com:27000, vmsec0521e.westus.cloudapp.azure.com:27000/testoc?replicaSet=rs0521e&quot;;&lt;/p&gt;

&lt;p&gt;System.TimeoutException: A timeout occured after 30000ms selecting a server using CompositeServerSelector{ Selectors = ReadPreferenceServerSelector{ ReadPreference = &lt;/p&gt;
{ Mode = Primary, TagSets = System.Collections.Generic.List`1[MongoDB.Driver.TagSet] }
&lt;p&gt; }, LatencyLimitingServerSelector&lt;/p&gt;
{ AllowedLatencyRange = 00:00:00.0150000 }
&lt;p&gt; }. Client view of cluster state is { ClusterId : &quot;1&quot;, Type : &quot;ReplicaSet&quot;, State : &quot;Disconnected&quot;, Servers : [{ ServerId: &quot;&lt;/p&gt;
{ ClusterId : 1, EndPoint : &quot;Unspecified/ vmsec0521e.westus.cloudapp.azure.com:27000&quot; }
&lt;p&gt;&quot;, EndPoint: &quot;Unspecified/ vmsec0521e.westus.cloudapp.azure.com:27000&quot;, State: &quot;Disconnected&quot;, Type: &quot;Unknown&quot;, HeartbeatException: &quot;MongoDB.Driver.MongoConnectionException: An exception occurred while opening a connection to the server. ---&amp;gt; System.Net.Sockets.SocketException: No such host is known&lt;br/&gt;
   at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)&lt;br/&gt;
   at System.Threading.Tasks.TaskFactory`1.FromAsyncCoreLogic(IAsyncResult iar, Func`2 endFunction, Action`1 endAction, Task`1 promise, Boolean requiresSynchronization)&lt;/p&gt;

&lt;h3&gt;&lt;a name=&quot;reprobykillingmongodprocessinPrimaryvmpri0521e&quot;&gt;&lt;/a&gt;repro by killing mongod process in Primary vmpri0521e&lt;/h3&gt;
&lt;p&gt;connection string: &quot;mongodb://&amp;lt;userName&amp;gt;:&amp;lt;passWord&amp;gt;@vmpri0521e.westus.cloudapp.azure.com:27000, vmsec0521e.westus.cloudapp.azure.com:27000/testoc?replicaSet=rs0521e&quot;;&lt;/p&gt;

&lt;p&gt;at MongoDB.Driver.Core.Servers.ClusterableServer.&amp;lt;HeartbeatAsync&amp;gt;d__d.MoveNext()&quot; }, { ServerId: &quot;&lt;/p&gt;
{ ClusterId : 1, EndPoint : &quot;Unspecified/vmpri0521e.westus.cloudapp.azure.com:27000&quot; }
&lt;p&gt;&quot;, EndPoint: &quot;Unspecified/vmpri0521e.westus.cloudapp.azure.com:27000&quot;, State: &quot;Disconnected&quot;, Type: &quot;Unknown&quot;, HeartbeatException: &quot;MongoDB.Driver.MongoConnectionException: An exception occurred while opening a connection to the server. ---&amp;gt; System.Net.Sockets.SocketException: No connection could be made because the target machine actively refused it 191.236.92.13:27000&lt;/p&gt;</comment>
                            <comment id="922825" author="craiggwilson" created="Mon, 25 May 2015 19:51:35 +0000"  >&lt;p&gt;Hi &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=tryshi&quot; class=&quot;user-hover&quot; rel=&quot;tryshi&quot;&gt;tryshi&lt;/a&gt;,&lt;/p&gt;

&lt;p&gt;We certainly don&apos;t require all seeds to be available. If that is happening, it would be a bug. This is a scenario we test, so I&apos;m keen to understand what is going on.  Could you provide your connection string/configuration code and/or provide a simple set of code we can reproduce this with.&lt;/p&gt;

&lt;p&gt;Craig&lt;/p&gt;</comment>
                    </comments>
                    <attachments>
                            <attachment id="75874" name="logs.zip" size="100040" author="tryshi" created="Wed, 27 May 2015 15:16:20 +0000"/>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_15850" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hs9mpj:</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>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            </customfields>
    </item>
</channel>
</rss>