<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 03:59:55 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-22280] Sockets/connections created and left hanging</title>
                <link>https://jira.mongodb.org/browse/SERVER-22280</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;It&apos;s a fairly hard thing to reproduce, so bear with me... also, I&apos;m not sure if the problem is in the node driver or in mongodb itself, so I&apos;m going to try to log it in both places&lt;/p&gt;</description>
                <environment>AWS VM Environment, 3 mongo replicaset across regions with IPSEC tunnel</environment>
        <key id="260243">SERVER-22280</key>
            <summary>Sockets/connections created and left hanging</summary>
                <type id="1" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14703&amp;avatarType=issuetype">Bug</type>
                                            <priority id="3" iconUrl="https://jira.mongodb.org/images/icons/priorities/major.svg">Major - P3</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="-1">Unassigned</assignee>
                                    <reporter username="roberto@leibman.net">Roberto Leibman</reporter>
                        <labels>
                    </labels>
                <created>Fri, 22 Jan 2016 17:43:58 +0000</created>
                <updated>Tue, 26 Jan 2016 20:10:22 +0000</updated>
                            <resolved>Tue, 26 Jan 2016 16:46:37 +0000</resolved>
                                    <version>3.2.0</version>
                                                    <component>Replication</component>
                                        <votes>0</votes>
                                    <watches>4</watches>
                                                                                                                <comments>
                            <comment id="1154178" author="roberto@leibman.net" created="Tue, 26 Jan 2016 17:26:42 +0000"  >&lt;p&gt;Thomas, &lt;br/&gt;
Is there anything in my description that leads you to think it is not a bug in either the driver or the server? &lt;/p&gt;

&lt;p&gt;It seems to me that when the server shows thousands of connections open and the client only requested a pool of 100 there&apos;s a bug somewhere. &lt;/p&gt;

&lt;p&gt;Yes, I agree that the user group may give me some advice on how to work around the bug (and thanks for the suggestion, I just posted the question), but ultimately it&apos;s a matter of thousands of connections (with their sockets) open when I only asked for 100. You want to blame the driver, by all means, one way or the other, it&apos;s still a bug. &lt;/p&gt;
</comment>
                            <comment id="1154140" author="thomas.schubert" created="Tue, 26 Jan 2016 16:46:38 +0000"  >&lt;p&gt;Hi &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=roberto%40leibman.net&quot; class=&quot;user-hover&quot; rel=&quot;roberto@leibman.net&quot;&gt;roberto@leibman.net&lt;/a&gt;,&lt;/p&gt;

&lt;p&gt;I would reccomend posting this question 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;. The user group provides MongoDB-related support and may be able to help you narrow down this issue. If after further investigation there is evidence of a bug in the MongoDB server, please comment on this ticket or a open a new ticket.&lt;/p&gt;

&lt;p&gt;Thank you,&lt;br/&gt;
Thomas&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10010">
                    <name>Duplicate</name>
                                            <outwardlinks description="duplicates">
                                        <issuelink>
            <issuekey id="260242">NODE-645</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                                        </outwardlinks>
                                                        </issuelinktype>
                    </issuelinks>
                <attachments>
                    </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>Fri, 22 Jan 2016 23:24:18 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        8 years, 3 weeks, 1 day 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>
                            8 years, 3 weeks, 1 day ago
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                    <customfield id="customfield_10032" key="com.atlassian.jira.plugin.system.customfieldtypes:select">
                        <customfieldname>Operating System</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="10020"><![CDATA[Linux]]></customfieldvalue>

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

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hshmdj:</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_23361" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Requested By</customfieldname>
                        <customfieldvalues>
                                

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                            <customfield id="customfield_10750" key="com.atlassian.jira.plugin.system.customfieldtypes:textarea">
                        <customfieldname>Steps To Reproduce</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>&lt;p&gt;The environment&lt;br/&gt;
----------------------&lt;br/&gt;
I have an environment split among two Amazon Region (OR and VA). &lt;br/&gt;
OR: 1 NAT, 1 SVC, 2 Mongo &lt;br/&gt;
VA: 1 NAT, 1 SVC, 1 Mongo (with priority = 0)&lt;br/&gt;
Both regions are connected by an ipsec tunnel managed by the 2 NAT machines, such that all traffic between regions goes through this tunnel,&lt;br/&gt;
The SVC machines each run 3 different services, each of these node services keeps a connection pool for their duration. The connection is made with the following url:&lt;/p&gt;

&lt;p&gt;var url = &apos;mongodb://10.56.4.54:27017,10.72.3.114:27017,10.72.4.96:27017/mydatabase?maxPoolSize=100&amp;amp;replicaSet=replica-set-name&apos;&lt;/p&gt;

&lt;p&gt;It all seems to be running fine, until the IPSEC tunnel goes down. &quot;mongostat --discover&quot; shows roughly 600 connections spread accross all 3 mongo servers.&lt;/p&gt;

&lt;p&gt;When the tunnel goes down (even if momentarily), the services on the OR region function correctly, the services on the VA region function for a little bit until their local Mongo realizes it&apos;s disconnected, at which point they just hang. &lt;/p&gt;

&lt;p&gt;The problem is when the tunnel goes back up. At that point hundreds of connections ACCROSS the tunnel are made, almost as if each bad connection in each connection pool was causing a whole other connection pool. Of course, if my ulimit is set too low mongo stops accepting connections. Mongo sees these open connections as idle (dbCurrentOp(true) shows them as active=false). Using lsof (or netstat) I can see that the extra connections are TCP sockets in ESTABLISHED state accross the tunnel (from the mongo box they show as being opened to the ipsec box, NOT to their originating box on the other side of the tunnel). If I kill the services in the SVC boxes the connections do go away.&lt;/p&gt;</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>
                                

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

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