<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 06:14:16 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-69745] Memory not entirely used, Mongo uses swap</title>
                <link>https://jira.mongodb.org/browse/SERVER-69745</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;On a production 3 nodes mongodb replicaset we&apos;re observing that the db is using only 60% of the ram, then it uses the swap memory. This causes severe slowness at application level.&lt;/p&gt;

&lt;p&gt;Parameter &quot;cacheSize&quot; is not set: from the docs we read that by default mongo will use 50% of the avalaible ram minus 1Gb.&lt;/p&gt;

&lt;p&gt;OS swappiness parameter is set to 1.&lt;/p&gt;

&lt;p&gt;We see that is suggested to avoid increasing WT internal cache size above its default value.&lt;/p&gt;

&lt;p&gt;Would it be ok to increase it anyway, in this case?&lt;br/&gt;
Otherwise, increasing server ram could be a solution?&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;Thank you.&lt;/p&gt;</description>
                <environment>Red Hat Enterprise Linux Server release 7.6 (Maipo) &lt;br/&gt;
Mongodb with 3 replicaset</environment>
        <key id="2135070">SERVER-69745</key>
            <summary>Memory not entirely used, Mongo uses swap</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="chris.kelly@mongodb.com">Chris Kelly</assignee>
                                    <reporter username="desk@sorint.it">Sorint Lab</reporter>
                        <labels>
                            <label>WiredTiger</label>
                            <label>cache</label>
                            <label>cachesize</label>
                            <label>memory-management</label>
                    </labels>
                <created>Tue, 13 Sep 2022 14:17:48 +0000</created>
                <updated>Tue, 27 Sep 2022 10:19:00 +0000</updated>
                            <resolved>Tue, 27 Sep 2022 10:04:03 +0000</resolved>
                                                                                        <votes>0</votes>
                                    <watches>5</watches>
                                                                                                                <comments>
                            <comment id="4857744" author="JIRAUSER1265262" created="Tue, 27 Sep 2022 10:02:21 +0000"  >&lt;p&gt;Hello,&lt;/p&gt;

&lt;p&gt;After looking at your diagnostic data, I see a pattern of queuing/high utilization occurring on your storage disks where time is spent waiting on &lt;b&gt;ss wt cache application threads page read from disk to cache.&lt;/b&gt;&#160;The most time always seems to be spent going from disk to cache, and not the other way around. This correlates with increases in your &lt;b&gt;system memory swap cached.&lt;/b&gt;&lt;/p&gt;

&lt;p&gt;Your WT cache contains about 25GB, or 80% at basically all times. However, your&#160;&lt;b&gt;ss mem resident&lt;/b&gt; is fluctuating between 35GB and 44GB alongside instances of memory fragmentation. You could consider experimenting with swappiness or trying &lt;em&gt;tcmallocAggressiveMemoryDecommit&lt;/em&gt; to aggressively return the free pages to the OS where they can be reused by tcmalloc to satisfy new memory requests:&lt;/p&gt;

&lt;p&gt;db.adminCommand( { setParameter: 1, tcmallocAggressiveMemoryDecommit: 1 } )&lt;/p&gt;

&lt;p&gt;&lt;span class=&quot;image-wrap&quot; style=&quot;&quot;&gt;&lt;img src=&quot;https://jira.mongodb.org/secure/attachment/404420/404420_image-2022-09-27-05-58-57-580.png&quot; style=&quot;border: 0px solid black&quot; /&gt;&lt;/span&gt;&lt;/p&gt;

&lt;p&gt;In general, there is a cyclic pattern of memory fragmentation occurring every few hours it seems which could be contributing to this issue as pages are loaded from disk to cache. There could be other possibilities however.&lt;/p&gt;

&lt;p&gt;MongoDB 4.0 &lt;a href=&quot;https://www.mongodb.com/support-policy/legacy&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;reached end of life in April 2022&lt;/a&gt; and is no longer supported, so I&apos;m going to close this ticket for now.&#160; If you suspect a bug in 4.2+ however, we would be interested in investigating it here in the SERVER project. I recommend consulting the &lt;a href=&quot;https://www.mongodb.com/community/forums&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;MongoDB Developer Community Forums&lt;/a&gt; for additional information in the meantime.&#160;&lt;/p&gt;

&lt;p&gt;Regards,&lt;/p&gt;

&lt;p&gt;Christopher&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;</comment>
                            <comment id="4830765" author="JIRAUSER1265262" created="Thu, 15 Sep 2022 15:28:19 +0000"  >&lt;p&gt;Hello,&lt;/p&gt;

&lt;p&gt;We have received your files and will update the ticket when we have further information.&lt;/p&gt;

&lt;p&gt;Christopher&lt;/p&gt;</comment>
                            <comment id="4829461" author="JIRAUSER1271146" created="Thu, 15 Sep 2022 08:04:51 +0000"  >&lt;p&gt;Hello Chris,&lt;/p&gt;

&lt;p&gt;can you confirm you received the files?&lt;/p&gt;

&lt;p&gt;Is there any update?&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;Thank you.&lt;/p&gt;</comment>
                            <comment id="4825548" author="JIRAUSER1271146" created="Wed, 14 Sep 2022 13:20:01 +0000"  >&lt;p&gt;Hello,&lt;/p&gt;

&lt;p&gt;we attached the files requested.&lt;/p&gt;

&lt;p&gt;The issue has been occurring for several weeks but it intensified during the last days, so we provided you with logs from yesterday and today.&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;Thank you.&lt;/p&gt;</comment>
                            <comment id="4823685" author="JIRAUSER1265262" created="Tue, 13 Sep 2022 19:22:02 +0000"  >&lt;p&gt;Hello,&lt;/p&gt;

&lt;p&gt;I&apos;ve created a secure &lt;a href=&quot;https://amphora.corp.mongodb.com/public/upload/eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJmb2xkZXJfaWQiOiIxNzI4MDA3NzMyNzEiLCJleHAiOjE2NjU2ODg4NjB9.aZc5A5PU-vMnAfSsPWnMMoWDOM81YR4ec5spwmPn2eM&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;upload portal&lt;/a&gt; for you. Files uploaded to this portal are hosted on Box, are visible only to MongoDB employees, and are routinely deleted after some time.&lt;/p&gt;

&lt;p&gt;For each node in the replica set spanning a time period that includes the incident, would you please archive (tar or zip) and upload to that link:&lt;/p&gt;

&lt;ul&gt;
	&lt;li&gt;the mongod logs&lt;/li&gt;
	&lt;li&gt;the $dbpath/diagnostic.data directory (the contents are described here)&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;Regards,&lt;br/&gt;
Christopher&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10010">
                    <name>Duplicate</name>
                                                                <inwardlinks description="is duplicated by">
                                        <issuelink>
            <issuekey id="2137699">SERVER-69744</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                        <issuelink>
            <issuekey id="2134849">WT-9855</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                    </issuelinks>
                <attachments>
                            <attachment id="404419" name="image-2022-09-27-05-51-56-470.png" size="329365" author="chris.kelly@mongodb.com" created="Tue, 27 Sep 2022 09:51:59 +0000"/>
                            <attachment id="404420" name="image-2022-09-27-05-58-57-580.png" size="329365" author="chris.kelly@mongodb.com" created="Tue, 27 Sep 2022 09:59:00 +0000"/>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                <customfield id="customfield_10050" key="com.atlassian.jira.toolkit:comments">
                        <customfieldname># Replies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>5.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Tue, 13 Sep 2022 19:22:02 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        1 year, 19 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>chris.kelly@mongodb.com</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_11151" key="com.atlassian.jira.toolkit:LastCommentDate">
                        <customfieldname>Last public comment date</customfieldname>
                        <customfieldvalues>
                            1 year, 19 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="10026"><![CDATA[ALL]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_10051" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>chris.kelly@mongodb.com</customfieldvalue>
            <customfieldvalue>desk@sorint.it</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|i19yj3:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|i0solk:</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;Red Hat Enterprise Linux Server release 7.6 (Maipo) &lt;br/&gt;
Mongodb with 3 replicaset&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>
                                    <customfieldvalue><![CDATA[chris.kelly@mongodb.com]]></customfieldvalue>
    

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

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