<!-- 
RSS generated by JIRA (9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c) at Sat Feb 10 03:25:49 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-16305] mkfs.lustre fails on devices between 16TiB-32GiB and 16TiB-1B</title>
                <link>https://jira.whamcloud.com/browse/LU-16305</link>
                <project id="10000" key="LU">Lustre</project>
                    <description>&lt;p&gt;Attempting to mkfs.lustre a disk below 16TiB in size but above the value computed for &quot;resize&quot; by mkfs.lustre (for 4KiB blocks, 32GiB shy of 16TiB) results in a failure as mke2fs requires resize to be greater than the specified capacity.&lt;/p&gt;

&lt;p&gt;&lt;tt&gt;Example:&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;mkfs.lustre --ost --reformat --servicenode &amp;lt;elided&amp;gt; --fsname=lustrefs --index 1 --mgsnode &amp;lt;elided&amp;gt; --backfstype=ldiskfs /dev/ost1&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;mkfs.lustre FATAL: Unable to build fs /dev/ost1 (256)&lt;/tt&gt;&lt;tt&gt;mkfs.lustre FATAL: mkfs failed 256&lt;/tt&gt;&lt;tt&gt;&#160; &#160;Permanent disk data:&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;Target: &#160; &#160; lustrefs:OST0001&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;Index: &#160; &#160; &#160;1 &#160;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;Lustre FS: &#160;lustrefs&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;Mount type: ldiskfs&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;Flags: &#160; &#160; &#160;0x1062&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; &#160; &#160; &#160; &#160; &#160; (OST first_time update no_primnode )&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;Persistent mount opts: ,errors=remount-ro&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;Parameters: failover.node=&amp;lt;elided&amp;gt; mgsnode=&amp;lt;elided&amp;gt;&lt;/tt&gt;&lt;tt&gt;device size = 16777152MB&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;formatting backing filesystem ldiskfs on /dev/ost1&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; target name &#160; lustrefs:OST0001&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; kilobytes &#160; &#160; 17179803648&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; options &#160; &#160; &#160; &#160; -J size=1024 -I 512 -i 524288 -q -O extents,uninit_bg,mmp,dir_nlink,quota,project,huge_file,^fast_commit,flex_bg -G 256 -E resize=\&quot;4290772992\&quot;,lazy_journal_init=\&quot;0\&quot;,lazy_itable_init=\&quot;0\&quot; -F&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;mkfs_cmd = mke2fs -j -b 4096 -L lustrefs:OST0001 &#160; -J size=1024 -I 512 -i 524288 -q -O extents,uninit_bg,mmp,dir_nlink,quota,project,huge_file,^fast_commit,flex_bg -G 256 -E resize=\&quot;4290772992\&quot;,lazy_journal_init=\&quot;0\&quot;,lazy_itable_init=\&quot;0\&quot; -F /dev/ost1 17179803648k&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160;detected raid stride 4194304 too large, use optimum 512&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160;detected raid stripe width 67108864 too large, use optimum 512&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160;The resize maximum must be greater than the filesystem size.&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160;Bad option(s) specified:&lt;/tt&gt;&lt;tt&gt;&#160; &#160;Extended options are separated by commas, and may take an argument which&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; is set off by an equals (&apos;=&apos;) sign.&#160;&lt;/tt&gt;&lt;tt&gt;&#160; &#160;Valid extended options are:&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; mmp_update_interval=&amp;lt;interval&amp;gt;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; num_backup_sb=&amp;lt;0|1|2&amp;gt;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; stride=&amp;lt;RAID per-disk data chunk in blocks&amp;gt;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; stripe-width=&amp;lt;RAID stride * data disks in blocks&amp;gt;&#160;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; offset=&amp;lt;offset to create the file system&amp;gt;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; resize=&amp;lt;resize maximum size in blocks&amp;gt;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; packed_meta_blocks=&amp;lt;0 to disable, 1 to enable&amp;gt;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; lazy_itable_init=&amp;lt;0 to disable, 1 to enable&amp;gt;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; lazy_journal_init=&amp;lt;0 to disable, 1 to enable&amp;gt;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; root_owner=&amp;lt;uid of root dir&amp;gt;:&amp;lt;gid of root dir&amp;gt;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; test_fs&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; discard&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; nodiscard&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; encoding=&amp;lt;encoding&amp;gt;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; encoding_flags=&amp;lt;flags&amp;gt;&lt;/tt&gt;&lt;br/&gt;
&lt;tt&gt;&#160; &#160; quotatype=&amp;lt;quota type(s) to be enabled&amp;gt;&lt;/tt&gt;&lt;/p&gt;</description>
                <environment></environment>
        <key id="73173">LU-16305</key>
            <summary>mkfs.lustre fails on devices between 16TiB-32GiB and 16TiB-1B</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="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="elliswilson">Ellis Wilson</assignee>
                                    <reporter username="elliswilson">Ellis Wilson</reporter>
                        <labels>
                    </labels>
                <created>Wed, 9 Nov 2022 16:47:06 +0000</created>
                <updated>Sun, 13 Nov 2022 20:26:48 +0000</updated>
                                                                                <due></due>
                            <votes>0</votes>
                                    <watches>4</watches>
                                                                            <comments>
                            <comment id="352321" author="adilger" created="Wed, 9 Nov 2022 17:11:23 +0000"  >&lt;p&gt;Ellis, thanks for filing the ticket. Until this is fixed in the code, it should be possible to work around the issue by adding &quot;&lt;tt&gt;,^resize_inode&lt;/tt&gt;&quot; to the &quot;&lt;tt&gt;-O&lt;/tt&gt;&quot; feature list, and removing &quot;&lt;tt&gt;resize=4290772992,&lt;/tt&gt;&quot; from the &quot;&lt;tt&gt;-E&lt;/tt&gt;&quot; extended options list on the &lt;tt&gt;mkfs.lustre&lt;/tt&gt; command line.&lt;/p&gt;</comment>
                            <comment id="352327" author="JIRAUSER17317" created="Wed, 9 Nov 2022 17:34:04 +0000"  >&lt;p&gt;No problem!&#160; I fixed it with the following patch (going through the mechanics presently to test/submit the patch):&lt;/p&gt;

&lt;p&gt;&#160;&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;--- a/lustre/utils/libmount_utils_ldiskfs.c
+++ b/lustre/utils/libmount_utils_ldiskfs.c
@@ -885,6 +885,15 @@ int ldiskfs_make_lustre(struct mkfs_opts *mop)
&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; append_unique(start, ext_opts ? &quot;,&quot; : &quot; -E &quot;,
&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &quot;resize&quot;, buf, maxbuflen);
&#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; ext_opts = 1;
+
+ &#160; &#160; &#160; &#160; &#160; &#160; &#160; /* The resize maximum must be greater than filesystem size, but for disks
+ &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;* or arrays just shy of 16TiB you can get into a situation where capacity
+ &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;* is between resize_blks and 16TiB. &#160; &#160;Shrink the drive size to 1MiB less
+ &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;* than resize in these scenarios (at most ~0.1% capacity is lost).&#160;
+ &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;*/
+ &#160; &#160; &#160; &#160; &#160; &#160; &#160; if (resize_blks &amp;lt;= mop-&amp;gt;mo_device_kb / mop-&amp;gt;mo_blocksize_kb) {
+ &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; mop-&amp;gt;mo_device_kb = (long long)(resize_blks) * (long long)mop-&amp;gt;mo_blocksize_kb - 1024;
+ &#160; &#160; &#160; &#160; &#160; &#160; &#160; }
&#160; &#160; &#160; &#160; }
&#160;
&#160; &#160; &#160; &#160; /* Avoid zeroing out the full journal - speeds up mkfs */

{{&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;As posted on lustre-discuss, I have some questions about the intent behind resize, and IDK how to get this assigned to me (maybe that&apos;s only for WC people).&lt;/p&gt;</comment>
                            <comment id="352404" author="adilger" created="Thu, 10 Nov 2022 00:22:13 +0000"  >&lt;p&gt;Rather than shrink the MDT device, it would be better to just disable the &lt;tt&gt;resize_inode&lt;/tt&gt; feature for such filesystems, since it is not useful for filesystems over 16TiB anyway.&lt;/p&gt;</comment>
                            <comment id="352410" author="JIRAUSER17317" created="Thu, 10 Nov 2022 01:47:00 +0000"  >&lt;p&gt;I believe this only applies to OSTs, and while I can disable it I&apos;d like to better understand what the optimization is attempting to accomplish first.&#160; I think you put this block in around 2011 (could totally be wrong &#8211; it&apos;s moved around a few times).&#160; Do you remember what it was accomplishing?&#160; I&apos;m really struggling to understand this comment block:&lt;br/&gt;
&#160; &#160;871 &#160; /* In order to align the filesystem metadata on 1MB boundaries,&lt;br/&gt;
&#160; &#160;872 &#160; &#160;* give a resize value that will reserve a power-of-two group&lt;br/&gt;
&#160; &#160;873 &#160; &#160;* descriptor blocks, but leave one block for the superblock.&lt;br/&gt;
&#160; &#160;874 &#160; &#160;* Only useful for filesystems with &amp;lt; 2^32 blocks due to resize&lt;br/&gt;
&#160; &#160;875 &#160; &#160;* limitations.&lt;/p&gt;

&lt;p&gt;Is ext metadata really unaligned without specifying resize?&#160; Some docs suggest that without giving this, mke2fs plans for up to 1024 times the original size of the filesystem, so I don&apos;t feel like this is a case where we&apos;re trying to plan ahead more than mke2fs already does.&lt;/p&gt;</comment>
                            <comment id="352487" author="adilger" created="Thu, 10 Nov 2022 06:50:02 +0000"  >&lt;p&gt;The &lt;tt&gt;resize_inode&lt;/tt&gt; feature only works up to 16TB, so it is basically useless for the problematic filesystem and may as well be disabled for such filesystems. There is a different feature (&lt;tt&gt;meta_bg&lt;/tt&gt;) that is used for resizing filesystems beyond 16TB. The 1024x resize is based on a starting filesystem size that is much smaller. &lt;/p&gt;

&lt;p&gt;Yes, the ext4 metadata is not aligned to 1MB boundaries by default, and this option (along with some others added in the same patch)  ensures that other metadata was located with proper 1MB alignment for HDD RAID alignment. That is not so important for flash MDTs at this point either.&lt;/p&gt;

&lt;p&gt;So my approach to fixing this issue would be to disable the &lt;tt&gt;resize_inode&lt;/tt&gt; feature (if this isn&apos;t done automatically already) and not specify the &quot;&lt;tt&gt;-E resize=nnnn&lt;/tt&gt;&quot; option  for filesystems that are close to 16TB in size.&lt;/p&gt;</comment>
                            <comment id="352600" author="JIRAUSER17317" created="Thu, 10 Nov 2022 16:47:31 +0000"  >&lt;p&gt;Thanks for the clarification Andreas.&#160; I&apos;ve revised my in-house fix, and will run it through the steps on your submitting changes wiki shortly.&lt;/p&gt;</comment>
                            <comment id="352847" author="pjones" created="Sun, 13 Nov 2022 20:26:48 +0000"  >&lt;p&gt;&lt;a href=&quot;https://jira.whamcloud.com/secure/ViewProfile.jspa?name=elliswilson&quot; class=&quot;user-hover&quot; rel=&quot;elliswilson&quot;&gt;elliswilson&lt;/a&gt; I have added you to the developers group for the community project so you should now be able to do things like assign tickets to yourself etc&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_10030" key="com.atlassian.jira.plugin.system.customfieldtypes:labels">
                        <customfieldname>Epic/Theme</customfieldname>
                        <customfieldvalues>
                                        <label>ldiskfs</label>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_10390" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|i0356v:</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>