<!-- 
RSS generated by JIRA (9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c) at Sat Feb 10 01:05: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>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-247] Lustre client slow performance on BG/P IONs: unaligned DIRECT_IO</title>
                <link>https://jira.whamcloud.com/browse/LU-247</link>
                <project id="10000" key="LU">Lustre</project>
                    <description>&lt;p&gt;Port the fix of bug 18801 to 2.1&lt;/p&gt;</description>
                <environment></environment>
        <key id="10666">LU-247</key>
            <summary>Lustre client slow performance on BG/P IONs: unaligned DIRECT_IO</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="1">Fixed</resolution>
                                        <assignee username="niu">Niu Yawei</assignee>
                                    <reporter username="niu">Niu Yawei</reporter>
                        <labels>
                    </labels>
                <created>Thu, 28 Apr 2011 23:34:44 +0000</created>
                <updated>Thu, 17 Mar 2022 16:08:47 +0000</updated>
                            <resolved>Thu, 17 Mar 2022 16:08:47 +0000</resolved>
                                    <version>Lustre 2.0.0</version>
                                                        <due></due>
                            <votes>0</votes>
                                    <watches>9</watches>
                                                                            <comments>
                            <comment id="13639" author="niu" created="Wed, 4 May 2011 04:09:15 +0000"  >&lt;p&gt;I think there are two major components in this porting:&lt;/p&gt;

&lt;p&gt;1. Make bufferred lockless io into direct lockless io.&lt;/p&gt;

&lt;p&gt;  Current 2.0 code supports bufferred lockless io, we should make them into direct io, since:&lt;/p&gt;
&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;Partial write could cause data corrption: a partial write should make page uptodate by read page in prepare_write, since&lt;br/&gt;
    it&apos;s lockless io, the cached page isn&apos;t protected by dlm lock, then another client could change other part of this page&lt;br/&gt;
    just after prior client&apos;s prepare_write, when the prior client flush this page, the change made by the 2nd client will&lt;br/&gt;
    be overwritten by stale data.&lt;/li&gt;
	&lt;li&gt;In fact in the bufferred lockless io case, the page never been cached (it can&apos;t be cached), so it doesn&apos;t make any sense&lt;br/&gt;
    to copy data between user page and kernel cache, as shown in b18801, the overhead of such copy sometimes is quite heavy.&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;2. Support unaligned direct io.&lt;/p&gt;

&lt;p&gt;  To support unaligned direct io in 2.0, I think we&apos;d better build io request based on user pages and file offset directly,&lt;br/&gt;
  that should be similar to obd_brw api does. In my opinion, direct io doesn&apos;t fit those cl_xxx apis very well (they are &lt;br/&gt;
  designed for bufferred io, the page offset is tightly binding with file offset, I think), and I don&apos;t see what&apos;s the&lt;br/&gt;
  benefit of maitaining a raidx tree for those never cached user pages. &lt;/p&gt;


&lt;p&gt;Jay, Oleg&lt;br/&gt;
Does my propsal sound ok to you? Thanks.&lt;/p&gt;</comment>
                            <comment id="13676" author="jay" created="Wed, 4 May 2011 11:39:55 +0000"  >&lt;p&gt;Hi Niu,&lt;/p&gt;

&lt;p&gt;Thanks for the points. Yes, this is a good chance for us to fix the directIO problem in one shot.&lt;/p&gt;

&lt;p&gt;I still tend to do this upon the infrastructure of clio. Also the reason to have a radix tree in clio is for porting purpose - we&apos;ve done a lot of work to decouple linux vfs/vm in both MDT and client stack.&lt;/p&gt;

&lt;p&gt;Here is my idea: let&apos;s fix CPT_TRANSIENT page implementation to have arbitrary buffers for this kind of pages. However, this will not fit into cl_page cache any more which means stale data may be read if applications are doing regular IO and directIO on the same node. This may violate posix semantics a little bit, but I tend to think this is fine since linux kernel is doing the same thing.&lt;/p&gt;

&lt;p&gt;I&apos;m going to compose a draft patch for this. It should be easy.&lt;/p&gt;</comment>
                            <comment id="13720" author="jay" created="Thu, 5 May 2011 00:02:41 +0000"  >&lt;p&gt;Hi Niu,&lt;/p&gt;

&lt;p&gt;I composed a patch to bypass cl_page cache for TRANSIENT pages at: &lt;a href=&quot;http://review.whamcloud.com/#change,495&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://review.whamcloud.com/#change,495&lt;/a&gt;, just for a reference.&lt;/p&gt;</comment>
                            <comment id="13759" author="jay" created="Thu, 5 May 2011 13:09:45 +0000"  >&lt;p&gt;I realize we should give it a try because this may be not a problem in clio. Clio has a finer grained lockless IO control, it can do lockless IO per ost object, instead of per file as b18.&lt;/p&gt;</comment>
                            <comment id="13764" author="green" created="Thu, 5 May 2011 17:46:25 +0000"  >&lt;p&gt;Frankly I am not even sure why do we need radix trees or anything like that for directio or otherwise uncached pages.&lt;br/&gt;
It&apos;s a purely one-shot job anyway.&lt;/p&gt;

&lt;p&gt;Lai, your description of patchless io partial page write in clio where unlocked page is marked as clean sounds totally broken.&lt;br/&gt;
Good thing there is no easy way to trigger this mode or we&apos;d have another blocker on our hands.&lt;/p&gt;</comment>
                            <comment id="16543" author="pjones" created="Fri, 17 Jun 2011 10:18:25 +0000"  >&lt;p&gt;I think that we will defer this task for now&lt;/p&gt;</comment>
                            <comment id="16600" author="niu" created="Mon, 20 Jun 2011 07:31:18 +0000"  >&lt;p&gt;Patch is at &lt;a href=&quot;http://review.whamcloud.com/980&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://review.whamcloud.com/980&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="23479" author="niu" created="Mon, 28 Nov 2011 23:19:20 +0000"  >&lt;p&gt;The patch in &lt;a href=&quot;http://review.whamcloud.com/980&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://review.whamcloud.com/980&lt;/a&gt; uses obd_brw() API in osc_io_dio(), since it requires less code changes and easyer for landing, however, the best way to implement osc_io_dio() should be: introduce a new API which can naturally accept (file offset, bytes, offset in first page, incontiguous pages) and build io requests based on these information directly (brw_page should not be used for direct io, &apos;pshift&apos; hacking should be eliminated), and osc_io_dio() calls the new API to build io reqeusts and sends them asynchronously.&lt;/p&gt;

&lt;p&gt;The proper implementaion requires more code changes, let&apos;s fix it in a follow-up patch.&lt;/p&gt;</comment>
                            <comment id="66738" author="adilger" created="Mon, 16 Sep 2013 16:21:01 +0000"  >&lt;p&gt;I don&apos;t like the idea of adding new users of the obd_brw() APIs.  These are pretty much obsolete on both the client and server, and we should be removing them entirely instead of adding new users.&lt;/p&gt;</comment>
                            <comment id="67741" author="spitzcor" created="Thu, 26 Sep 2013 18:07:23 +0000"  >&lt;p&gt;If we follow Niu&apos;s suggestion to land change #980 and then follow it up, can it land now, or must we wait until after we branch for b2_5?&lt;/p&gt;</comment>
                            <comment id="329509" author="paf0186" created="Thu, 17 Mar 2022 16:08:47 +0000"  >&lt;p&gt;See &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-13805&quot; title=&quot;i/o path: Unaligned direct i/o&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-13805&quot;&gt;LU-13805&lt;/a&gt;&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Related</name>
                                            <outwardlinks description="is related to ">
                                        <issuelink>
            <issuekey id="55934">LU-12429</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="23274">LU-4664</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="21786">LU-4198</issuekey>
        </issuelink>
                            </outwardlinks>
                                                                <inwardlinks description="is related to">
                                        <issuelink>
            <issuekey id="18454">LU-3192</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="60032">LU-13805</issuekey>
        </issuelink>
                            </inwardlinks>
                                    </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                                                                                    <customfield id="customfield_10020" key="com.atlassian.jira.plugin.system.customfieldtypes:float">
                        <customfieldname>Bugzilla ID</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>18801.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                            <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|hzvvev:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10090" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>9105</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>