<!-- 
RSS generated by JIRA (9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c) at Sat Feb 10 02:13:56 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-8021] interop: 2.1.x server &lt;-&gt; clients version &gt; 2.3: t-f debugsave() debugrestore() defect</title>
                <link>https://jira.whamcloud.com/browse/LU-8021</link>
                <project id="10000" key="LU">Lustre</project>
                    <description>&lt;p&gt;test-framework.sh :&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;debugsave() {
    DEBUGSAVE=&lt;span class=&quot;code-quote&quot;&gt;&quot;$(lctl get_param -n debug)&quot;&lt;/span&gt;
}
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&amp;#8211; DEBUGSAVE is equal to value set on client&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;debugrestore() {
    [ -n &lt;span class=&quot;code-quote&quot;&gt;&quot;$DEBUGSAVE&quot;&lt;/span&gt; ] &amp;amp;&amp;amp; \
        do_nodes $(comma_list $(nodes_list)) &lt;span class=&quot;code-quote&quot;&gt;&quot;$LCTL set_param debug=\\\&quot;&lt;/span&gt;${DEBUGSAVE}\\\&lt;span class=&quot;code-quote&quot;&gt;&quot;;&quot;&lt;/span&gt;
    DEBUGSAVE=&quot;&quot;
}
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&amp;#8211; sets debug=$DEBUGSAVE on all nodes including the server nodes.&lt;br/&gt;
I.e. debugrestore () does not restore the initial debug values set on servers, but sets the debug value equal to initial debug value set on client.&lt;/p&gt;

&lt;p&gt;Intel clients (starting from 2.3, D_LFSCK added by &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-957&quot; title=&quot;LFSCK fix Object Index for MDT file-level backup/restore for lustre-2.x&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-957&quot;&gt;&lt;del&gt;LU-957&lt;/del&gt;&lt;/a&gt;) have some debugging masks are missing on 2.1.x servers.&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;libcfs_debug.h :
#define D_SEC           0x08000000
#define D_LFSCK         0x10000000 &lt;span class=&quot;code-comment&quot;&gt;/* For both OI scrub and LFSCK */&lt;/span&gt;
#define D_HSM           0x20000000
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;


&lt;p&gt;The described debugsave() and debugrestore() defect leads the tests to fail when run with PTLDEBUG=-1 because of EINVAL returned by lctl executed on servers:&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;+ debugrestore
...
+ /usr/bin/pdsh -R ssh -S -w fre0205,fre0206,fre0207,fre0208 &lt;span class=&quot;code-quote&quot;&gt;&apos;(PATH=$PATH:/usr/lib64/lustre/utils:/usr/lib64/lustre/tests:/sbin:/usr/sbin; cd /usr/lib64/lustre/tests; LUSTRE=&lt;span class=&quot;code-quote&quot;&gt;&quot;/usr/lib64/lustre&quot;&lt;/span&gt;  FSTYPE=ldiskfs sh -c &lt;span class=&quot;code-quote&quot;&gt;&quot;/usr/sbin/lctl set_param debug=\&quot;&lt;/span&gt;trace inode &lt;span class=&quot;code-keyword&quot;&gt;super&lt;/span&gt; ext2 malloc cache info ioctl neterror net warning buffs other dentry nettrace page dlmtrace error emerg ha rpctrace vfstrace reada mmap config console quota sec lfsck\&lt;span class=&quot;code-quote&quot;&gt;&quot;;&quot;&lt;/span&gt;)&apos;&lt;/span&gt;
fre0206: error: set_param: writing to file /proc/sys/lnet/debug: Invalid argument
pdsh@fre0207: fre0206: ssh exited with exit code 1
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;Reproducible on 2.1 Server &amp;lt;-&amp;gt; 2.5.1 client.&lt;/li&gt;
&lt;/ul&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;== sanity test 63b: async write errors should be returned to fsync ===== 21:43:48 (1457502228)
debug=-1
1+0 records in
1+0 records out
4096 bytes (4.1 kB) copied, 0.00600947 s, 682 kB/s
fail_loc=0x80000406
fsync: Input/output error
192.18.177.138: error: set_param: setting /proc/sys/lnet/debug=trace inode super ext2 malloc cache info ioctl neterror net warning buffs other dentry nettrace page dlmtrace error emerg ha rpctrace vfstrace reada mmap config console quota sec lfsck hsm: Invalid argument
pdsh@osh-1: 192.18.177.138: ssh exited with exit code 1
debug=trace inode super ext2 malloc cache info ioctl neterror net warning buffs other dentry nettrace page dlmtrace error emerg ha rpctrace vfstrace reada mmap config console quota sec lfsck hsm
debug=trace inode super ext2 malloc cache info ioctl neterror net warning buffs other dentry nettrace page dlmtrace error emerg ha rpctrace vfstrace reada mmap config console quota sec lfsck hsm
Resetting fail_loc and fail_val on all nodes...done.
PASS 63b (13s)
resend_count is set to 4 4
resend_count is set to 4 4
resend_count is set to 4 4
resend_count is set to 4 4
resend_count is set to 4 4
== sanity test complete, duration 235 sec == 21:44:02 (1457502242)
Stopping clients: osh-1.xyus.xyratex.com /mnt/lustre (opts:-f)
Stopping client osh-1.xyus.xyratex.com /mnt/lustre opts:-f
Stopping clients: osh-1.xyus.xyratex.com /mnt/lustre2 (opts:-f)
Stopping /mnt/mds1 (opts:-f) on 192.18.177.138
Stopping /mnt/ost1 (opts:-f) on 192.18.177.138
Stopping /mnt/ost2 (opts:-f) on 192.18.177.138
modules unloaded.
[root@osh-1 tests]# 



-----------

2.1.x server

[root@osh-1 ~]# lctl set_param -n debug=-1
You have new mail in /var/spool/mail/root
[root@osh-1 ~]# lctl get_param -n debug
trace inode super ext2 malloc cache info ioctl neterror net warning buffs other dentry nettrace page dlmtrace error emerg ha rpctrace vfstrace reada mmap config console quota sec
[root@osh-1 ~]#

2.5.1 client
[root@osh-1 tests]# lctl set_param -n debug=-1
[root@osh-1 tests]# lctl get_param -n debug
trace inode super ext2 malloc cache info ioctl neterror net warning buffs other dentry nettrace page dlmtrace error emerg ha rpctrace vfstrace reada mmap config console quota sec *lfsck hsm*
[root@osh-1 tests]#

-------------
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;</description>
                <environment></environment>
        <key id="36137">LU-8021</key>
            <summary>interop: 2.1.x server &lt;-&gt; clients version &gt; 2.3: t-f debugsave() debugrestore() defect</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="emoly.liu">Emoly Liu</assignee>
                                    <reporter username="parinay">parinay v kondekar</reporter>
                        <labels>
                            <label>patch</label>
                    </labels>
                <created>Thu, 14 Apr 2016 06:26:27 +0000</created>
                <updated>Thu, 27 Oct 2016 17:44:20 +0000</updated>
                            <resolved>Wed, 21 Sep 2016 15:17:43 +0000</resolved>
                                    <version>Lustre 2.1.5</version>
                                    <fixVersion>Lustre 2.9.0</fixVersion>
                                        <due></due>
                            <votes>0</votes>
                                    <watches>6</watches>
                                                                            <comments>
                            <comment id="148956" author="adilger" created="Thu, 14 Apr 2016 17:21:15 +0000"  >&lt;p&gt;Probably the right solution is to have a separate DEBUGSAVE_OSS and DEBUGSAVE_MDS to hold the server values (assume they are the same on all servers) between debugsave() and debugrestore().&lt;/p&gt;</comment>
                            <comment id="149053" author="parinay" created="Fri, 15 Apr 2016 06:18:00 +0000"  >&lt;p&gt;Andreas,&lt;/p&gt;
&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;I had created and tested following patch. I used a single var DEBUGSAVE_SERVER instead of what you suggested  and client debug flags are continued to be saved in DEBUGSAVE.&lt;/li&gt;
&lt;/ul&gt;


&lt;ul class=&quot;alternate&quot; type=&quot;square&quot;&gt;
	&lt;li&gt;Also this issue is seen in case of interop and when PTLDEBUG=-1 is set.&lt;/li&gt;
&lt;/ul&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;diff --git a/lustre/tests/test-framework.sh b/lustre/tests/test-framework.sh
index ac11c8f..6149963 100755
--- a/lustre/tests/test-framework.sh
+++ b/lustre/tests/test-framework.sh
@@ -4570,13 +4570,24 @@ pgcache_empty() {
 }
 
 debugsave() {
-    DEBUGSAVE=&lt;span class=&quot;code-quote&quot;&gt;&quot;$(lctl get_param -n debug)&quot;&lt;/span&gt;
+       DEBUGSAVE=&lt;span class=&quot;code-quote&quot;&gt;&quot;$($LCTL get_param -n debug)&quot;&lt;/span&gt;
+       DEBUGSAVE_SERVER=$(do_facet $SINGLEMDS &lt;span class=&quot;code-quote&quot;&gt;&quot;$LCTL get_param -n debug&quot;&lt;/span&gt;)
 }
 
 debugrestore() {
-    [ -n &lt;span class=&quot;code-quote&quot;&gt;&quot;$DEBUGSAVE&quot;&lt;/span&gt; ] &amp;amp;&amp;amp; 
-        do_nodes $(comma_list $(nodes_list)) &lt;span class=&quot;code-quote&quot;&gt;&quot;$LCTL set_param debug=\\\&quot;&lt;/span&gt;${DEBUGSAVE}\\\&lt;span class=&quot;code-quote&quot;&gt;&quot;;&quot;&lt;/span&gt;
-    DEBUGSAVE=&quot;&quot;
+       local SERVERS=$(comma_list $(mdts_nodes) $(osts_nodes))
+
+       [ -n &lt;span class=&quot;code-quote&quot;&gt;&quot;$DEBUGSAVE&quot;&lt;/span&gt; ] &amp;amp;&amp;amp; 
+               do_nodes $CLIENTS \
+               &lt;span class=&quot;code-quote&quot;&gt;&quot;$LCTL set_param debug=\\\&quot;&lt;/span&gt;${DEBUGSAVE}\\\&lt;span class=&quot;code-quote&quot;&gt;&quot;;&quot;&lt;/span&gt;
+       DEBUGSAVE=&quot;&quot;
+
+       [ -n &lt;span class=&quot;code-quote&quot;&gt;&quot;DEBUGSAVE_SERVER&quot;&lt;/span&gt; ] &amp;amp;&amp;amp; 
+               do_nodes $SERVERS \
+               &lt;span class=&quot;code-quote&quot;&gt;&quot;$LCTL set_param debug=\\\&quot;&lt;/span&gt;${DEBUGSAVE_SERVER}\\\&lt;span class=&quot;code-quote&quot;&gt;&quot;;&quot;&lt;/span&gt;
+
+       DEBUGSAVE_SERVER=&quot;&quot;
+
 }
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Do you think, I should go ahead and change DEBUGSAVE_SERVER into  DEBUGSAVE_MDS and DEBUGSAVE_OSS or the present patch looks good.?&lt;/p&gt;

&lt;p&gt;Appreciate your time.&lt;br/&gt;
Thanks&lt;/p&gt;</comment>
                            <comment id="149069" author="gerrit" created="Fri, 15 Apr 2016 12:39:24 +0000"  >&lt;p&gt;Parinay Kondekar (parinay.kondekar@seagate.com) uploaded a new patch: &lt;a href=&quot;http://review.whamcloud.com/19604&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://review.whamcloud.com/19604&lt;/a&gt;&lt;br/&gt;
Subject: &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-8021&quot; title=&quot;interop: 2.1.x server &amp;lt;-&amp;gt; clients version &amp;gt; 2.3: t-f debugsave() debugrestore() defect&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-8021&quot;&gt;&lt;del&gt;LU-8021&lt;/del&gt;&lt;/a&gt; tests: In interop, ensure to save/restore correct debug flags&lt;br/&gt;
Project: fs/lustre-release&lt;br/&gt;
Branch: master&lt;br/&gt;
Current Patch Set: 1&lt;br/&gt;
Commit: d8fb09f453e8c419611d12a6e655d3047d40d968&lt;/p&gt;</comment>
                            <comment id="158425" author="gerrit" created="Mon, 11 Jul 2016 23:56:57 +0000"  >&lt;p&gt;Oleg Drokin (oleg.drokin@intel.com) merged in patch &lt;a href=&quot;http://review.whamcloud.com/19604/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://review.whamcloud.com/19604/&lt;/a&gt;&lt;br/&gt;
Subject: &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-8021&quot; title=&quot;interop: 2.1.x server &amp;lt;-&amp;gt; clients version &amp;gt; 2.3: t-f debugsave() debugrestore() defect&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-8021&quot;&gt;&lt;del&gt;LU-8021&lt;/del&gt;&lt;/a&gt; tests: In interop, ensure to save/restore correct debug flags&lt;br/&gt;
Project: fs/lustre-release&lt;br/&gt;
Branch: master&lt;br/&gt;
Current Patch Set: &lt;br/&gt;
Commit: 77ae71b56e1ed44a0a80a95c465dafd1f41d2e86&lt;/p&gt;</comment>
                            <comment id="158659" author="jgmitter" created="Wed, 13 Jul 2016 18:09:28 +0000"  >&lt;p&gt;Patch has landed to master for 2.9.0&lt;/p&gt;</comment>
                            <comment id="165898" author="adilger" created="Tue, 13 Sep 2016 18:53:42 +0000"  >&lt;p&gt;This patch opened a defect in &lt;tt&gt;debugrestore()&lt;/tt&gt;:&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;CMD: trevis-27vm3,trevis-27vm4,trevis-27vm8 /usr/sbin/lctl set_param debug=\&quot;\&quot;
trevis-27vm4: error: set_param: setting debug: no value
trevis-27vm3: error: set_param: setting debug: no value
trevis-27vm8: error: set_param: setting debug: no value
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;The problem is in the newly added code:&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; debugrestore() {
+       [ -n &lt;span class=&quot;code-quote&quot;&gt;&quot;DEBUGSAVE_SERVER&quot;&lt;/span&gt; ] &amp;amp;&amp;amp;
+               do_nodes $(comma_list $(all_server_nodes)) \
+                        &lt;span class=&quot;code-quote&quot;&gt;&quot;$LCTL set_param debug=\\\&quot;&lt;/span&gt;${DEBUGSAVE_SERVER}\\\&quot;&quot;
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;This should actually be &lt;tt&gt;[ -n &quot;$DEBUGSAVE_SERVER&quot; ] &amp;amp;&amp;amp;&lt;/tt&gt; (note leading &lt;b&gt;$&lt;/b&gt; there.  Otherwise the check is always true and the code tries to restore an empty string and it produces a lot of spurious error messages in the test logs.&lt;/p&gt;

&lt;p&gt;Parinay, can you please submit a patch to fix this.  Note that it can use the &lt;tt&gt;Test-Parameters: trivial&lt;/tt&gt; tag to bypass most of the testing.&lt;/p&gt;</comment>
                            <comment id="166343" author="pjones" created="Mon, 19 Sep 2016 03:29:41 +0000"  >&lt;p&gt;Emoly is looking into this&lt;/p&gt;</comment>
                            <comment id="166357" author="emoly.liu" created="Mon, 19 Sep 2016 06:29:24 +0000"  >&lt;p&gt;Emoly Liu (emoly.liu@intel.com) uploaded a new patch: &lt;a href=&quot;http://review.whamcloud.com/22586&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://review.whamcloud.com/22586&lt;/a&gt;&lt;br/&gt;
Subject: &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-8021&quot; title=&quot;interop: 2.1.x server &amp;lt;-&amp;gt; clients version &amp;gt; 2.3: t-f debugsave() debugrestore() defect&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-8021&quot;&gt;&lt;del&gt;LU-8021&lt;/del&gt;&lt;/a&gt; tests: Add leading $ to &quot;DEBUGSAVE_SERVER&quot;&lt;br/&gt;
Project: fs/lustre-release&lt;br/&gt;
Branch: master&lt;br/&gt;
Current Patch Set: 1&lt;br/&gt;
Commit: 90910df9cf50f963868c0bd65af1ac0e9d6c141a&lt;/p&gt;</comment>
                            <comment id="166685" author="parinay" created="Wed, 21 Sep 2016 08:44:13 +0000"  >&lt;p&gt;Andreas,&lt;br/&gt;
Sorry I missed this notification, somehow it did not reach my mail &lt;img class=&quot;emoticon&quot; src=&quot;https://jira.whamcloud.com/images/icons/emoticons/sad.png&quot; height=&quot;16&quot; width=&quot;16&quot; align=&quot;absmiddle&quot; alt=&quot;&quot; border=&quot;0&quot;/&gt; .&lt;/p&gt;</comment>
                            <comment id="166700" author="gerrit" created="Wed, 21 Sep 2016 13:01:00 +0000"  >&lt;p&gt;Andreas Dilger (andreas.dilger@intel.com) merged in patch &lt;a href=&quot;http://review.whamcloud.com/22586/&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://review.whamcloud.com/22586/&lt;/a&gt;&lt;br/&gt;
Subject: &lt;a href=&quot;https://jira.whamcloud.com/browse/LU-8021&quot; title=&quot;interop: 2.1.x server &amp;lt;-&amp;gt; clients version &amp;gt; 2.3: t-f debugsave() debugrestore() defect&quot; class=&quot;issue-link&quot; data-issue-key=&quot;LU-8021&quot;&gt;&lt;del&gt;LU-8021&lt;/del&gt;&lt;/a&gt; tests: Add leading $ to &quot;DEBUGSAVE_SERVER&quot;&lt;br/&gt;
Project: fs/lustre-release&lt;br/&gt;
Branch: master&lt;br/&gt;
Current Patch Set: &lt;br/&gt;
Commit: 81f309421dafa9a7519634bb27f54faabd5ef852&lt;/p&gt;</comment>
                            <comment id="166717" author="pjones" created="Wed, 21 Sep 2016 15:17:43 +0000"  >&lt;p&gt;Landed to 2.9&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10010">
                    <name>Duplicate</name>
                                                                <inwardlinks description="is duplicated by">
                                                        </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|hzy807:</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>