<!-- 
RSS generated by JIRA (9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c) at Sat Feb 10 02: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-7267] e2fsck kill all files with Large EA.</title>
                <link>https://jira.whamcloud.com/browse/LU-7267</link>
                <project id="10000" key="LU">Lustre</project>
                    <description>&lt;p&gt;e2fsck start a killing any Large EA enabled files after wrong merging in 1.42.9 e2fsprogs.&lt;br/&gt;
after it point any run e2fsck produce an output&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;Pass 1: Checking inodes, blocks, and sizes
Extended attribute in inode 755994480 has a value size (5674) which is invalid
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;fix is simple - just restore old behavior in pass1.c : check_ea_in_inode() function.&lt;/p&gt;
&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;                &lt;span class=&quot;code-comment&quot;&gt;/* check value size */&lt;/span&gt;
-                &lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; (entry-&amp;gt;e_value_size &amp;gt; remain) {
+               &lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; (entry-&amp;gt;e_value_size == 0) {
                        pctx-&amp;gt;num = entry-&amp;gt;e_value_size;
                        problem = PR_1_ATTR_VALUE_SIZE;
                        &lt;span class=&quot;code-keyword&quot;&gt;goto&lt;/span&gt; fix;
                }
 
                &lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; (entry-&amp;gt;e_value_inum == 0) {
                        &lt;span class=&quot;code-comment&quot;&gt;/* check value size */&lt;/span&gt;
                        &lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; (entry-&amp;gt;e_value_size &amp;gt; remain) {
                                pctx-&amp;gt;num = entry-&amp;gt;e_value_size;
                                problem = PR_1_ATTR_VALUE_SIZE;
                                &lt;span class=&quot;code-keyword&quot;&gt;goto&lt;/span&gt; fix;
                        }
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;</description>
                <environment>e2fsck 1.42.12 (and looks 1.42.13)</environment>
        <key id="32545">LU-7267</key>
            <summary>e2fsck kill all files with Large EA.</summary>
                <type id="1" iconUrl="https://jira.whamcloud.com/secure/viewavatar?size=xsmall&amp;avatarId=11303&amp;avatarType=issuetype">Bug</type>
                                            <priority id="1" iconUrl="https://jira.whamcloud.com/images/icons/priorities/blocker.svg">Blocker</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="shadow">Alexey Lyashkov</reporter>
                        <labels>
                    </labels>
                <created>Thu, 8 Oct 2015 13:21:12 +0000</created>
                <updated>Tue, 3 Nov 2015 19:08:42 +0000</updated>
                            <resolved>Tue, 3 Nov 2015 19:08:42 +0000</resolved>
                                    <version>Lustre 2.8.0</version>
                                    <fixVersion>Lustre 2.8.0</fixVersion>
                                        <due></due>
                            <votes>0</votes>
                                    <watches>8</watches>
                                                                            <comments>
                            <comment id="129848" author="adilger" created="Thu, 8 Oct 2015 17:22:12 +0000"  >&lt;p&gt;There also needs to be an e2fsprogs test case for large xattrs. I&apos;m really surprised that there isn&apos;t already a test case that would have caught this regression. &lt;/p&gt;</comment>
                            <comment id="129849" author="jgmitter" created="Thu, 8 Oct 2015 17:23:30 +0000"  >&lt;p&gt;Hi Niu,&lt;br/&gt;
Can you have a look at this one?&lt;br/&gt;
Thanks.&lt;br/&gt;
Joe&lt;/p&gt;</comment>
                            <comment id="129862" author="shadow" created="Thu, 8 Oct 2015 18:19:35 +0000"  >&lt;p&gt;was wrong about checking to zero, we need a kill first check completely. corresponded commit in upstream.&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;Author: Eric Sandeen &amp;lt;sandeen@redhat.com&amp;gt;
Date:   Thu Apr 25 00:14:33 2013 -0400

    e2fsprogs: allow 0-length xattr values in e2fsck
    
    e2fsck thinks that this:
    
    # touch mnt/testfile1
    # setfattr -n &quot;user.test&quot; mnt/testfile1
    
    results in a filesystem with corruption:
    
    Pass 1: Checking inodes, blocks, and sizes
    Extended attribute in inode 12 has a value size (0) which is invalid
    Clear? yes
    
    but as far as I can tell, there is absolutely nothing wrong with
    a 0-length value on an extended attribute.  Just remove the check.
    
    Reported-by: David Shaw &amp;lt;dshaw@jabberwocky.com&amp;gt;
    Reported-by: Harald Reindl &amp;lt;h.reindl@thelounge.net&amp;gt;
    Addresses-Red-Hat-Bugzilla: #557959
    Signed-off-by: Eric Sandeen &amp;lt;sandeen@redhat.com&amp;gt;
    Signed-off-by: Theodore Ts&apos;o &amp;lt;tytso@mit.edu&amp;gt;
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;</comment>
                            <comment id="129915" author="niu" created="Fri, 9 Oct 2015 03:04:13 +0000"  >&lt;p&gt;There must be a wrong merge at some point which created this duplicated check, probably when merging the 10fc3a63d9b7efb14e810ee94ad1d2f254d44eae (the fix mentioned by Alexey above)&lt;/p&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;               &lt;span class=&quot;code-comment&quot;&gt;/* check value size */&lt;/span&gt;
                &lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; (entry-&amp;gt;e_value_size &amp;gt; remain) {
                        pctx-&amp;gt;num = entry-&amp;gt;e_value_size;
                        problem = PR_1_ATTR_VALUE_SIZE;
                        &lt;span class=&quot;code-keyword&quot;&gt;goto&lt;/span&gt; fix;
                }

                &lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; (entry-&amp;gt;e_value_inum == 0) {
                        &lt;span class=&quot;code-comment&quot;&gt;/* check value size */&lt;/span&gt;
                        &lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; (entry-&amp;gt;e_value_size &amp;gt; remain) {
                                pctx-&amp;gt;num = entry-&amp;gt;e_value_size;
                                problem = PR_1_ATTR_VALUE_SIZE;
                                &lt;span class=&quot;code-keyword&quot;&gt;goto&lt;/span&gt; fix;
                        }
                } &lt;span class=&quot;code-keyword&quot;&gt;else&lt;/span&gt; {
                        &lt;span class=&quot;code-object&quot;&gt;int&lt;/span&gt; ret, tmp;

                        ret = check_large_ea_inode(ctx, entry, pctx, &amp;amp;tmp);
                        &lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; (ret == 0)
                                mark_inode_ea_map(ctx, pctx,
                                                  entry-&amp;gt;e_value_inum);
                }
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Obviously, the duplicated check above the &quot; if (entry-&amp;gt;e_value_inum == 0) &quot; should be completely removed.&lt;/p&gt;</comment>
                            <comment id="129920" author="niu" created="Fri, 9 Oct 2015 05:00:55 +0000"  >&lt;p&gt;Andreas, I found that there is a test for the large xattr:&lt;/p&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;commit c204ac83b8889a81d8aeb2ea421ca14db796e5c6
Author: Andreas Dilger &amp;lt;andreas.dilger@intel.com&amp;gt;
Date:   Fri Apr 13 02:14:16 2012 -0600

    tests: verify large xattr inode support

    Verify that inodes with large EAs in a secondary inode are working:
    * EA inode needs to have EA_INODE_FL set
    * EA inode should reference parent inode number+generation

    Signed-off-by: Kalpak Shah &amp;lt;kalpak@sun.com&amp;gt;
    Signed-off-by: Andreas Dilger &amp;lt;andreas.dilger@intel.com&amp;gt;
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;But when I check into the image file under f_large_ea, seems none of the files have any xattr set (getfattr can&apos;t list any ea entries), and the inode size in the superblock is 128 (which is EXT2_GOOD_OLD_INODE_SIZE), so the check_ea_in_inode() won&apos;t be called at all.&lt;/p&gt;

&lt;p&gt;The troublesome here is that EA can be set on fs with 128 inode size (with EA_INODE enabled)? Looks a lot more changes are required to check large ea inode. (see check_inode_extra_space(), check_ea_in_inode()).&lt;/p&gt;</comment>
                            <comment id="129925" author="niu" created="Fri, 9 Oct 2015 06:49:20 +0000"  >&lt;p&gt;I was wrong about the large ea tests, the ea inode was checked when checking extend attribute blocks, so just removing the duplicated checking code in check_ea_in_inode() should be enough.&lt;/p&gt;</comment>
                            <comment id="129926" author="gerrit" created="Fri, 9 Oct 2015 06:53:32 +0000"  >&lt;p&gt;Niu Yawei (yawei.niu@intel.com) uploaded a new patch: &lt;a href=&quot;http://review.whamcloud.com/16779&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://review.whamcloud.com/16779&lt;/a&gt;&lt;br/&gt;
Subject: &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-7267&quot; title=&quot;e2fsck kill all files with Large EA.&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-7267&quot;&gt;&lt;del&gt;LU-7267&lt;/del&gt;&lt;/a&gt; e2fsck: remove duplicated ea value size check&lt;br/&gt;
Project: tools/e2fsprogs&lt;br/&gt;
Branch: master-lustre&lt;br/&gt;
Current Patch Set: 1&lt;br/&gt;
Commit: d2498fe35d2a12ef085f865f2edc9350a8b47f2b&lt;/p&gt;</comment>
                            <comment id="129928" author="adilger" created="Fri, 9 Oct 2015 07:24:32 +0000"  >&lt;p&gt;Niu, I was looking at the &lt;tt&gt;f_large_ea/image&lt;/tt&gt; file, and it does appear to have large xattrs:&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;e2fsck -fn image
:
:
Pass 1: Checking inodes, blocks, and sizes
Inode 12 has invalid extended attribute. EA inode 79 missing EA_INODE flag.
Clear? yes

Invalid backpointer from extended attribute inode 19 to parent inode 13.
Clear? yes

Inode 14 has invalid extended attribute. EA inode 20 missing EA_INODE flag.
Clear? yes
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&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;debugfs:  stat &amp;lt;19&amp;gt;
Inode: 19   Type: regular    Mode:  0600   Flags: 0x280000
Generation: 3943742063    Version: 0x00000001
User:     0   Group:     0   Size: 65536
File ACL: 0    Directory ACL: 0
Links: 1   Blockcount: 128
Fragment:  Address: 0    Number: 0    Size: 0
ctime: 0x49193fdf -- Tue Nov 11 01:18:39 2008
atime: 0x49193fdf -- Tue Nov 11 01:18:39 2008
mtime: 0x0000000f -- Wed Dec 31 17:00:15 1969
EXTENTS:
(0-14):1567-1581, (15-63):1261-1309
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
</comment>
                            <comment id="130673" author="gerrit" created="Fri, 16 Oct 2015 18:29:09 +0000"  >&lt;p&gt;Andreas Dilger (andreas.dilger@intel.com) merged in patch &lt;a href=&quot;http://review.whamcloud.com/16779/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://review.whamcloud.com/16779/&lt;/a&gt;&lt;br/&gt;
Subject: &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-7267&quot; title=&quot;e2fsck kill all files with Large EA.&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-7267&quot;&gt;&lt;del&gt;LU-7267&lt;/del&gt;&lt;/a&gt; e2fsck: remove duplicated ea value size check&lt;br/&gt;
Project: tools/e2fsprogs&lt;br/&gt;
Branch: master-lustre&lt;br/&gt;
Current Patch Set: &lt;br/&gt;
Commit: 709edd7febe7831c01c406cc1552b7c288502a8b&lt;/p&gt;</comment>
                            <comment id="130680" author="adilger" created="Fri, 16 Oct 2015 19:33:33 +0000"  >&lt;p&gt;Patch is landed, but still need to make a new e2fsprogs release with this patch included.&lt;/p&gt;</comment>
                            <comment id="132525" author="adilger" created="Tue, 3 Nov 2015 19:08:42 +0000"  >&lt;p&gt;Close this ticket, as we also need to land &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-7368&quot; title=&quot;e2fsck unsafe to interrupt with quota enabled&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-7368&quot;&gt;&lt;del&gt;LU-7368&lt;/del&gt;&lt;/a&gt; as well and we can use that for tracking. &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|hzxpvj:</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>