<!-- 
RSS generated by JIRA (9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c) at Sat Feb 10 03:07:25 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-14168] e2fsck should avoid moving files into lost+found</title>
                <link>https://jira.whamcloud.com/browse/LU-14168</link>
                <project id="10000" key="LU">Lustre</project>
                    <description>&lt;p&gt;When e2fsck finds a directory that is hard-linked between an existing directory and lost+found, it appears to prefer moving the file into &lt;tt&gt;lost+found&lt;/tt&gt; rather than keeping it connected to the original parent directory:&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;&apos;..&apos; in /lost+found/#471345273 (471345273) is /ROOT/RUNDIRS/2018051500/output (471373040), should be /lost+found (11).
Fix? no
Entry &apos;tmp249767&apos; in /ROOT/RUNDIRS/2018051500/output (471373040) is a link to directory /lost+found/#471345273 (471345273 fid=[0x200039c0f:0x1d51c:0x0]).
Inode 471345273 ref count is 2, should be 3.  Fix? no
Entry &apos;#471345273&apos; in /lost+found (11) has an incorrect filetype (was 1, should be 2).
Fix? no
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;It would make more sense for &lt;tt&gt;e2fsck&lt;/tt&gt; to prefer &lt;b&gt;not&lt;/b&gt; moving files into &lt;tt&gt;lost+found&lt;/tt&gt; if there is somewhere else that the inode could be attached.&lt;/p&gt;</description>
                <environment></environment>
        <key id="61830">LU-14168</key>
            <summary>e2fsck should avoid moving files into lost+found</summary>
                <type id="4" iconUrl="https://jira.whamcloud.com/secure/viewavatar?size=xsmall&amp;avatarId=11310&amp;avatarType=issuetype">Improvement</type>
                                            <priority id="3" iconUrl="https://jira.whamcloud.com/images/icons/priorities/major.svg">Major</priority>
                        <status id="1" iconUrl="https://jira.whamcloud.com/images/icons/statuses/open.png" description="The issue is open and ready for the assignee to start work on it.">Open</status>
                    <statusCategory id="2" key="new" colorName="default"/>
                                    <resolution id="-1">Unresolved</resolution>
                                        <assignee username="wc-triage">WC Triage</assignee>
                                    <reporter username="adilger">Andreas Dilger</reporter>
                        <labels>
                            <label>e2fsprogs</label>
                    </labels>
                <created>Tue, 1 Dec 2020 23:01:16 +0000</created>
                <updated>Mon, 31 Jan 2022 23:33:37 +0000</updated>
                                                                                <due></due>
                            <votes>0</votes>
                                    <watches>2</watches>
                                                                            <comments>
                            <comment id="319921" author="adilger" created="Thu, 2 Dec 2021 20:27:02 +0000"  >&lt;p&gt;I think the main obstacle to linking directory inodes back into the original parent directory (based on the inode number stored in &lt;tt&gt;..&lt;/tt&gt;) is that e2fsck would normally not know the filename.  For Lustre filesystems, the correct filename can be found in a number of ways:&lt;/p&gt;
&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;for MDTs with &lt;tt&gt;REMOTE_PARENT_DIR&lt;/tt&gt; as the parent (most common case for MDTs other than MDT0000) the filename is the FID, which is stored in the &lt;tt&gt;trusted.lma&lt;/tt&gt; xattr in the inode&lt;/li&gt;
	&lt;li&gt;for MDTs where &lt;tt&gt;REMOTE_PARENT_DIR&lt;/tt&gt; is &lt;b&gt;not&lt;/b&gt; the parent, the filename for a particular parent directory FID can normally be found in the &lt;tt&gt;trusted.link&lt;/tt&gt; xattr, unless the file has hundreds of links and &lt;tt&gt;trusted.link&lt;/tt&gt; is full&lt;/li&gt;
	&lt;li&gt;for OSTs the parent will normally be object directories under &lt;tt&gt;O/&amp;lt;seq&amp;gt;/d&amp;#42;&lt;/tt&gt;, and the filename is the FID OID (decimal for &lt;tt&gt;f_seq=0&lt;/tt&gt;, hex for all others), and the FID can also be extracted from the &lt;tt&gt;trusted.lma&lt;/tt&gt; xattr&lt;/li&gt;
&lt;/ul&gt;


&lt;p&gt;Being able to correctly repair the directory entry in the parent, rather than dumping all files into &lt;tt&gt;lost+found&lt;/tt&gt; would avoid a considerable amount of duplicate work (add entry to &lt;tt&gt;lost+found&lt;/tt&gt;, update &lt;tt&gt;..&lt;/tt&gt;, fix link count, then repair it again later by OI Scrub or LFSCK).  The only drawback is that this would be specific to Lustre unless we can implement &lt;tt&gt;trusted.link&lt;/tt&gt; for upstream ext4 (ideally with the same on-disk format using &lt;tt&gt;struct link_ea_header&lt;/tt&gt; and &lt;tt&gt;struct link_ea_entry&lt;/tt&gt;, otherwise with a different xattr name and/or &lt;tt&gt;leh_magic&lt;/tt&gt;).&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Related</name>
                                            <outwardlinks description="is related to ">
                                                        </outwardlinks>
                                                                <inwardlinks description="is related to">
                                        <issuelink>
            <issuekey id="24144">LU-4876</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="67698">LU-15388</issuekey>
        </issuelink>
            <issuelink>
            <issuekey id="65449">LU-14894</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|i01g5z:</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>
                                                                                                                                                                                                                                                                                                                                                                                                                </customfields>
    </item>
</channel>
</rss>