<!-- 
RSS generated by JIRA (9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c) at Sat Feb 10 02:21:44 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-8926] Race in in job stats code results in untracked I/O</title>
                <link>https://jira.whamcloud.com/browse/LU-8926</link>
                <project id="10000" key="LU">Lustre</project>
                    <description>&lt;p&gt;There is a race condition between updating the job id in lustre_get_jobid and setting the job id in outbound RPCs (primarily when getting the job id from the an environment variable is enabled).&lt;/p&gt;

&lt;p&gt;The function lustre_get_jobid is used near the beginning of every I/O to set the job id in the Lustre inode info (lli_jobid, from vvp_io_init)), and then the job id is read out from there when building an RPC.  (osc_build_rpc, cl_req_attr_set, vvp_req_attr_set, then it&apos;s used in lustre_msg_set_jobid).&lt;/p&gt;

&lt;p&gt;lustre_get_jobid starts out by memsetting the jobid to zero, then re-reading it from the source.  Since osc_build_rpc is asynchronous from this and happens in another thread, it can read the jobid at any time, including while it&apos;s zero.&lt;/p&gt;

&lt;p&gt;Since cfs_get_environ is a very expensive operation, this can happen a lot for small IO operations.&lt;/p&gt;

&lt;p&gt;In particular, with 4k write operations, we see up to 2/3 of our IOs with a null job id, so they are not tracked.&lt;/p&gt;

&lt;p&gt;Using a lock or other hard synchronization here would be far too expensive, and it&apos;s OK if job stats are occasionally inaccurate.  So my proposed patch just cuts the window in which the jobid will be invalid from very large to very small.  (Also, in practice, the job id should not change much in the cases we really care about, namely when set from a job scheduler.)&lt;/p&gt;</description>
                <environment></environment>
        <key id="42329">LU-8926</key>
            <summary>Race in in job stats code results in untracked I/O</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="paf">Patrick Farrell</assignee>
                                    <reporter username="paf">Patrick Farrell</reporter>
                        <labels>
                    </labels>
                <created>Thu, 8 Dec 2016 21:29:09 +0000</created>
                <updated>Tue, 24 Jan 2017 14:33:07 +0000</updated>
                            <resolved>Tue, 24 Jan 2017 14:33:07 +0000</resolved>
                                                    <fixVersion>Lustre 2.10.0</fixVersion>
                                        <due></due>
                            <votes>0</votes>
                                    <watches>3</watches>
                                                                            <comments>
                            <comment id="177145" author="gerrit" created="Thu, 8 Dec 2016 21:49:36 +0000"  >&lt;p&gt;Patrick Farrell (paf@cray.com) uploaded a new patch: &lt;a href=&quot;https://review.whamcloud.com/24253&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://review.whamcloud.com/24253&lt;/a&gt;&lt;br/&gt;
Subject: &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-8926&quot; title=&quot;Race in in job stats code results in untracked I/O&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-8926&quot;&gt;&lt;del&gt;LU-8926&lt;/del&gt;&lt;/a&gt; llite: reduce jobstats race window&lt;br/&gt;
Project: fs/lustre-release&lt;br/&gt;
Branch: master&lt;br/&gt;
Current Patch Set: 1&lt;br/&gt;
Commit: 6de41ac2a36d89fa5e6864c7497e922de24289cf&lt;/p&gt;</comment>
                            <comment id="181857" author="gerrit" created="Tue, 24 Jan 2017 05:23:54 +0000"  >&lt;p&gt;Oleg Drokin (oleg.drokin@intel.com) merged in patch &lt;a href=&quot;https://review.whamcloud.com/24253/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://review.whamcloud.com/24253/&lt;/a&gt;&lt;br/&gt;
Subject: &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-8926&quot; title=&quot;Race in in job stats code results in untracked I/O&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-8926&quot;&gt;&lt;del&gt;LU-8926&lt;/del&gt;&lt;/a&gt; llite: reduce jobstats race window&lt;br/&gt;
Project: fs/lustre-release&lt;br/&gt;
Branch: master&lt;br/&gt;
Current Patch Set: &lt;br/&gt;
Commit: 8eca92b365fd3efd1541a48b1bb239926838d947&lt;/p&gt;</comment>
                            <comment id="181903" author="pjones" created="Tue, 24 Jan 2017 14:33:07 +0000"  >&lt;p&gt;Landed for 2.10&lt;/p&gt;</comment>
                    </comments>
                    <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|hzyxyv:</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>