<!-- 
RSS generated by JIRA (9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c) at Sat Feb 10 02:53:53 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-12585] obdfilter read_bytes stat reports requested read bytes and not actual read bytes</title>
                <link>https://jira.whamcloud.com/browse/LU-12585</link>
                <project id="10000" key="LU">Lustre</project>
                    <description>&lt;p&gt;&lt;tt&gt;obdfilter.*.stats&lt;/tt&gt; has a &lt;tt&gt;read_bytes&lt;/tt&gt; metric. This metrics reports the number of requested bytes, and not what I was expecting, what was actually read bytes from the OST.&lt;/p&gt;

&lt;p&gt;By example, if you have a 1MB file, and you try to read 16MB from it, the{{ read_bytes}} will likely reports 16MB and not 1MB.&lt;/p&gt;

&lt;p&gt;To reproduce:&lt;/p&gt;
&lt;div class=&quot;preformatted panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;preformattedContent panelContent&quot;&gt;
&lt;pre&gt;# llmount.sh

# dd if=/dev/zero of=/mnt/lustre/dump bs=1M count=1
# lctl set_param -n ldlm.namespaces.*.lru_size=clear

# dd if=/mnt/lustre/dump of=/dev/null bs=16M count=1
# lctl get_param obdfilter.*.stats | grep read_bytes
read_bytes 4 samples [bytes] 4194304 4194304 16777216
&#160;&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;I think this comes from the fact that the stats is updated at I/O preparation, and not I/O completion.&lt;/p&gt;

&lt;p&gt;Is this intended? I think we should either:&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;Fix the stat to store the actual read bytes&lt;/li&gt;
	&lt;li&gt;Or, add a second stat to store the actual read bytes if we don&apos;t want to change this one&lt;/li&gt;
&lt;/ul&gt;
</description>
                <environment></environment>
        <key id="56481">LU-12585</key>
            <summary>obdfilter read_bytes stat reports requested read bytes and not actual read bytes</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="paf0186">Patrick Farrell</assignee>
                                    <reporter username="degremoa">Aurelien Degremont</reporter>
                        <labels>
                    </labels>
                <created>Wed, 24 Jul 2019 09:47:13 +0000</created>
                <updated>Sat, 12 Mar 2022 05:11:25 +0000</updated>
                            <resolved>Mon, 7 Feb 2022 14:49:51 +0000</resolved>
                                    <version>Lustre 2.10.7</version>
                    <version>Lustre 2.12.1</version>
                                    <fixVersion>Lustre 2.15.0</fixVersion>
                                        <due></due>
                            <votes>0</votes>
                                    <watches>7</watches>
                                                                            <comments>
                            <comment id="292956" author="adilger" created="Thu, 25 Feb 2021 00:38:10 +0000"  >&lt;p&gt;in newer Lustre releases, there is:&lt;/p&gt;
&lt;div class=&quot;preformatted panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;preformattedContent panelContent&quot;&gt;
&lt;pre&gt;osd-ldiskfs.myth-OST0000.stats=
snapshot_time             1614211618.617166153 secs.nsecs
get_page                  92759 samples [usec] 0 103 426203 4154059
cache_access              20606 samples [pages] 1 1024 16346835
cache_hit                 4869 samples [pages] 1 1024 342396
cache_miss                20005 samples [pages] 1 1024 16004439
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;which shows whether pages are coming from cache or from disk.&lt;/p&gt;

&lt;p&gt;That said, with patch &lt;a href=&quot;https://review.whamcloud.com/38816&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://review.whamcloud.com/38816&lt;/a&gt; &quot;&lt;tt&gt;&lt;a href=&quot;https://jira.whamcloud.com/browse/LU-13597&quot; title=&quot;add processing time/latency, IO sizes, stats to job_stats&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-13597&quot;&gt;&lt;del&gt;LU-13597&lt;/del&gt;&lt;/a&gt; ofd: add more information to job_stats&lt;/tt&gt;&quot; the read stats are now stored after all of the pages have been read, so it would be trivial to replace &quot;&lt;tt&gt;tot_bytes&lt;/tt&gt;&quot; with an actual counter of the bytes read. &lt;/p&gt;</comment>
                            <comment id="322503" author="gerrit" created="Wed, 12 Jan 2022 20:43:52 +0000"  >&lt;p&gt;&quot;Patrick Farrell &amp;lt;pfarrell@whamcloud.com&amp;gt;&quot; uploaded a new patch: &lt;a href=&quot;https://review.whamcloud.com/46075&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://review.whamcloud.com/46075&lt;/a&gt;&lt;br/&gt;
Subject: &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-12585&quot; title=&quot;obdfilter read_bytes stat reports requested read bytes and not actual read bytes&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-12585&quot;&gt;&lt;del&gt;LU-12585&lt;/del&gt;&lt;/a&gt; obdfilter: Use actual I/O bytes in stats&lt;br/&gt;
Project: fs/lustre-release&lt;br/&gt;
Branch: master&lt;br/&gt;
Current Patch Set: 1&lt;br/&gt;
Commit: 34cbc31a9e73498d7f9324e942c85fbc44791c83&lt;/p&gt;</comment>
                            <comment id="323299" author="gerrit" created="Thu, 20 Jan 2022 15:18:59 +0000"  >&lt;p&gt;&quot;Patrick Farrell &amp;lt;pfarrell@whamcloud.com&amp;gt;&quot; uploaded a new patch: &lt;a href=&quot;https://review.whamcloud.com/46229&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://review.whamcloud.com/46229&lt;/a&gt;&lt;br/&gt;
Subject: &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-12585&quot; title=&quot;obdfilter read_bytes stat reports requested read bytes and not actual read bytes&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-12585&quot;&gt;&lt;del&gt;LU-12585&lt;/del&gt;&lt;/a&gt; mdt: Add read/write latency to MDT stats&lt;br/&gt;
Project: fs/lustre-release&lt;br/&gt;
Branch: master&lt;br/&gt;
Current Patch Set: 1&lt;br/&gt;
Commit: 6af42177e90e323d8d53878db3e2f56dd096b0ab&lt;/p&gt;</comment>
                            <comment id="325404" author="gerrit" created="Mon, 7 Feb 2022 04:44:02 +0000"  >&lt;p&gt;&quot;Oleg Drokin &amp;lt;green@whamcloud.com&amp;gt;&quot; merged in patch &lt;a href=&quot;https://review.whamcloud.com/46075/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://review.whamcloud.com/46075/&lt;/a&gt;&lt;br/&gt;
Subject: &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-12585&quot; title=&quot;obdfilter read_bytes stat reports requested read bytes and not actual read bytes&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-12585&quot;&gt;&lt;del&gt;LU-12585&lt;/del&gt;&lt;/a&gt; obdfilter: Use actual I/O bytes in stats&lt;br/&gt;
Project: fs/lustre-release&lt;br/&gt;
Branch: master&lt;br/&gt;
Current Patch Set: &lt;br/&gt;
Commit: 1c98e950fa7c9fac3d7494278abebee7c64c5397&lt;/p&gt;</comment>
                            <comment id="325405" author="gerrit" created="Mon, 7 Feb 2022 04:44:17 +0000"  >&lt;p&gt;&quot;Oleg Drokin &amp;lt;green@whamcloud.com&amp;gt;&quot; merged in patch &lt;a href=&quot;https://review.whamcloud.com/46229/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://review.whamcloud.com/46229/&lt;/a&gt;&lt;br/&gt;
Subject: &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-12585&quot; title=&quot;obdfilter read_bytes stat reports requested read bytes and not actual read bytes&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-12585&quot;&gt;&lt;del&gt;LU-12585&lt;/del&gt;&lt;/a&gt; mdt: Add read/write latency to MDT stats&lt;br/&gt;
Project: fs/lustre-release&lt;br/&gt;
Branch: master&lt;br/&gt;
Current Patch Set: &lt;br/&gt;
Commit: a942fc916871eebe6615fe8e29471e2386d46f1d&lt;/p&gt;</comment>
                            <comment id="325439" author="pjones" created="Mon, 7 Feb 2022 14:49:51 +0000"  >&lt;p&gt;Landed for 2.15&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Related</name>
                                                                <inwardlinks description="is related to">
                                        <issuelink>
            <issuekey id="69087">LU-15642</issuekey>
        </issuelink>
                            </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|i00k47:</customfieldvalue>

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