<!-- 
RSS generated by JIRA (9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c) at Sat Feb 10 01:10:45 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>Whamcloud Community JIRA</title>
    <link>https://jira.whamcloud.com</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>9.4.14</version>
        <build-number>940014</build-number>
        <build-date>05-12-2023</build-date>
    </build-info>


<item>
            <title>[LU-823] Lustre breaks cgroups accounting</title>
                <link>https://jira.whamcloud.com/browse/LU-823</link>
                <project id="10000" key="LU">Lustre</project>
                    <description>&lt;p&gt;Lustre implements its own copy of truncate_complete_page() in lustre_patchless_compat.h to allow the client to build against an unpatched kernel.  Unfortunately, of course, this means that lustre can break the kernel if it doesn&apos;t keep its copy in sync.&lt;/p&gt;

&lt;p&gt;Lustre&apos;s copy of truncate_complete_page() is out of date and breaks, at a minimum, linux&apos;s cgroup accounting.  To work around this problem we have decided to temporarily patch our kernel to have it export truncate_complete_page() and allow Lustre to use the kernel&apos;s function.&lt;/p&gt;

&lt;p&gt;Obviously the quick-and-dirty fix for Lustre is to add additional autoconf checks and update its copy of truncate_complete_page() and other associated functions.  But that whole approach is pretty unsettling.&lt;/p&gt;

&lt;p&gt;I would first like to check if there is some other similar function that the kernel exports now that we can start using.  Failing that, perhaps we can borrow Brian&apos;s trick from ZFS for using a symbol that hasn&apos;t been exported.&lt;/p&gt;</description>
                <environment>RHEL 6.1, 6.2 (possibly earlier), other kernels with cgroups support</environment>
        <key id="12330">LU-823</key>
            <summary>Lustre breaks cgroups accounting</summary>
                <type id="1" iconUrl="https://jira.whamcloud.com/secure/viewavatar?size=xsmall&amp;avatarId=11303&amp;avatarType=issuetype">Bug</type>
                                            <priority id="4" iconUrl="https://jira.whamcloud.com/images/icons/priorities/minor.svg">Minor</priority>
                        <status id="5" iconUrl="https://jira.whamcloud.com/images/icons/statuses/resolved.png" description="A resolution has been taken, and it is awaiting verification by reporter. From here issues are either reopened, or are closed.">Resolved</status>
                    <statusCategory id="3" key="done" colorName="success"/>
                                    <resolution id="2">Won&apos;t Fix</resolution>
                                        <assignee username="niu">Niu Yawei</assignee>
                                    <reporter username="morrone">Christopher Morrone</reporter>
                        <labels>
                    </labels>
                <created>Thu, 3 Nov 2011 16:08:33 +0000</created>
                <updated>Thu, 24 Nov 2022 00:07:28 +0000</updated>
                            <resolved>Tue, 10 Apr 2012 14:59:05 +0000</resolved>
                                    <version>Lustre 2.1.0</version>
                    <version>Lustre 2.2.0</version>
                                    <fixVersion>Lustre 2.4.0</fixVersion>
                                        <due></due>
                            <votes>0</votes>
                                    <watches>6</watches>
                                                                            <comments>
                            <comment id="22456" author="pjones" created="Thu, 3 Nov 2011 17:44:04 +0000"  >&lt;p&gt;Chris&lt;/p&gt;

&lt;p&gt;Could you check whether the tip of master still exhibits this problem? Oleg wonders whether this landing may have helped - &lt;a href=&quot;http://git.whamcloud.com/?p=fs/lustre-release.git;a=commit;h=1515e409cc57af5eaef809eee6d8f8d6725d092b&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://git.whamcloud.com/?p=fs/lustre-release.git;a=commit;h=1515e409cc57af5eaef809eee6d8f8d6725d092b&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Peter&lt;/p&gt;</comment>
                            <comment id="22459" author="morrone" created="Thu, 3 Nov 2011 19:35:53 +0000"  >&lt;p&gt;I think that patch comment could have used a larger comment.  Why is it ok to switch from calling truncate_complete_page() to calling remove_page_from_cache() when remove_page_from_cache() is only one of several things that truncate_complete_page() does?&lt;/p&gt;

&lt;p&gt;But unfortunately, RHEL 6.2 doesn&apos;t export either delete_from_page_cache or remove_from_page_cache, so that page doesn&apos;t address the problem.&lt;/p&gt;</comment>
                            <comment id="22460" author="morrone" created="Thu, 3 Nov 2011 19:39:06 +0000"  >&lt;p&gt;The upstream linux commit (a52116aba5b3eed0ee41f70b794cc1937acd5cb8) to export remove_from_page_cache is just a one-line that doesn&apos;t do anything else.  We are going to take a stab at getting RHEL to cherry-pick that into the RHEL6.2 kernel, but they are close to freezing the kernel so we probably shouldn&apos;t hold our breath.&lt;/p&gt;

&lt;p&gt;In any event, it would not help folks using cgroups on earlier RHEL6 releases.&lt;/p&gt;</comment>
                            <comment id="22466" author="morrone" created="Thu, 3 Nov 2011 22:40:52 +0000"  >&lt;p&gt;Oh, nevermind my comment about replacing truncate_complete_page with the other calls.  Now I see how the functions nest.&lt;/p&gt;

&lt;p&gt;But the problem still remains:  no call to mem_cgroup_uncharge_cache_page&lt;/p&gt;

&lt;p&gt;And isn&apos;t it incorrect to use cfs_* lock functions when the kernel is using the normal kernel locking functions on the same locks?  Granted, the cfs_* functions are just #defines to the kernel functions, but it doesn&apos;t seem correct to use cfs_* functions when these are cfs_* locks.&lt;/p&gt;</comment>
                            <comment id="22468" author="adilger" created="Thu, 3 Nov 2011 23:26:36 +0000"  >&lt;p&gt;I agree - cfs_* wrappers shouldn&apos;t be used on kernel structures.  I&apos;ve noticed this in a few places.&lt;/p&gt;</comment>
                            <comment id="22616" author="pjones" created="Mon, 7 Nov 2011 09:07:31 +0000"  >&lt;p&gt;Niu&lt;/p&gt;

&lt;p&gt;Could you please look into what changes are needed here?&lt;/p&gt;

&lt;p&gt;Thanks&lt;/p&gt;

&lt;p&gt;Peter&lt;/p&gt;</comment>
                            <comment id="22658" author="niu" created="Tue, 8 Nov 2011 00:08:10 +0000"  >&lt;p&gt;truncate_inode_pages_range() can serve the similar function like truncate_complete_page(), but it&apos;s not as efficient as calling truncate_complete_page() directly, since it&apos;ll re-lookup &amp;amp; re-lock the page internally, I think that&apos;s why we didn&apos;t use it at the very begining, and given that remove_page_from_cache() will be exported in later kernel, I don&apos;t think it&apos;s wise to make changes(quite a few) to use the truncate_inode_pages_range().&lt;/p&gt;

&lt;p&gt;If uer really want both cgroup and patchless client, I think we have to adopt the way of hacking to use un-exported symboles (Chirs, could you provide the details of this?), otherwise, we can document that patchless client doesn&apos;t support cgroup for those kernels (early 2.6.32).&lt;/p&gt;</comment>
                            <comment id="34357" author="niu" created="Tue, 10 Apr 2012 02:07:07 +0000"  >&lt;p&gt;Chris, are you ok with my previous comment? Declare that cgroup isn&apos;t supportted on patchless client with early 2.6.32 kernels, and use remove_from_page_cache() whenever it&apos;s exported in later kernel version. Thanks.&lt;/p&gt;</comment>
                            <comment id="34457" author="morrone" created="Tue, 10 Apr 2012 14:43:52 +0000"  >&lt;p&gt;I suppose I don&apos;t care too much since we decided to backport the kernel export.&lt;/p&gt;

&lt;p&gt;This business of copying kernel functions into lustre and hoping they are correct is very very ugly.  But since this particular problem will go away in the future with newer kernels that export more useful symbols, I think we just leave it as it is for now.&lt;/p&gt;</comment>
                            <comment id="34462" author="pjones" created="Tue, 10 Apr 2012 14:59:05 +0000"  >&lt;p&gt;ok thanks Chris&lt;/p&gt;</comment>
                            <comment id="34517" author="mark" created="Wed, 11 Apr 2012 08:15:22 +0000"  >&lt;p&gt;FYI, I think this is a straight duplicate of &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-620&quot; title=&quot;&amp;quot;Bad page state&amp;quot; reported after unlink&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-620&quot;&gt;&lt;del&gt;LU-620&lt;/del&gt;&lt;/a&gt;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Related</name>
                                                                <inwardlinks description="is related to">
                                                        </inwardlinks>
                                    </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                                                                                                                                            <customfield id="customfield_10890" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                        <customfield id="customfield_10390" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hzvhrj:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10090" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>6527</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_10060" key="com.atlassian.jira.plugin.system.customfieldtypes:select">
                        <customfieldname>Severity</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="10022"><![CDATA[3]]></customfieldvalue>

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