<div dir="ltr">GFAPI observes ENOENT with glfs_stat() - so the fix is necessary. </div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Dec 18, 2013 at 9:55 PM, Pranith Kumar Karampuri <span dir="ltr">&lt;<a href="mailto:pkarampu@redhat.com" target="_blank">pkarampu@redhat.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5"><br>
<br>
----- Original Message -----<br>
&gt; From: &quot;Vijay Bellur&quot; &lt;<a href="mailto:vbellur@redhat.com">vbellur@redhat.com</a>&gt;<br>
&gt; To: &quot;Pranith Kumar Karampuri&quot; &lt;<a href="mailto:pkarampu@redhat.com">pkarampu@redhat.com</a>&gt;, &quot;Venkatesh Somyajulu&quot; &lt;<a href="mailto:vsomyaju@redhat.com">vsomyaju@redhat.com</a>&gt;<br>
&gt; Cc: <a href="mailto:gluster-devel@nongnu.org">gluster-devel@nongnu.org</a><br>
&gt; Sent: Thursday, December 19, 2013 9:59:01 AM<br>
&gt; Subject: Re: [Gluster-devel] upstream: Symbolic link not getting healed<br>
&gt;<br>
&gt; On 12/19/2013 07:58 AM, Pranith Kumar Karampuri wrote:<br>
&gt; &gt; hi,<br>
&gt; &gt;      I used the following test to figure out the bad commit.<br>
&gt; &gt; #!/bin/bash<br>
&gt; &gt;<br>
&gt; &gt; . $(dirname $0)/../include.rc<br>
&gt; &gt; . $(dirname $0)/../volume.rc<br>
&gt; &gt;<br>
&gt; &gt; function trigger_mount_self_heal {<br>
&gt; &gt;          find $M0 | xargs stat<br>
&gt; &gt; }<br>
&gt; &gt;<br>
&gt; &gt; cleanup;<br>
&gt; &gt;<br>
&gt; &gt; TEST glusterd<br>
&gt; &gt; TEST pidof glusterd<br>
&gt; &gt; TEST $CLI volume create $V0 replica 2 $H0:$B0/${V0}{0,1}<br>
&gt; &gt; TEST $CLI volume set $V0 cluster.background-self-heal-count 0<br>
&gt; &gt; TEST $CLI volume start $V0<br>
&gt; &gt; TEST glusterfs --volfile-id=/$V0 --volfile-server=$H0 $M0 --use-readdirp=no<br>
&gt; &gt; --attribute-timeout=0 --entry-timeout=0<br>
&gt; &gt; TEST touch $M0/a<br>
&gt; &gt; TEST kill_brick $V0 $H0 $B0/${V0}0<br>
&gt; &gt; TEST ln -s $M0/a $M0/s<br>
&gt; &gt; TEST ! stat $B0/${V0}0/s<br>
&gt; &gt; TEST stat $B0/${V0}1/s<br>
&gt; &gt; TEST $CLI volume start $V0 force<br>
&gt; &gt; EXPECT_WITHIN 20 &quot;Y&quot; glustershd_up_status<br>
&gt; &gt; EXPECT_WITHIN 20 &quot;1&quot; afr_child_up_status_in_shd $V0 0<br>
&gt; &gt; TEST $CLI volume heal $V0 full<br>
&gt; &gt; TEST trigger_mount_self_heal<br>
&gt; &gt; TEST stat $B0/${V0}0/s<br>
&gt; &gt; TEST stat $B0/${V0}1/s<br>
&gt; &gt; cleanup<br>
&gt; &gt;<br>
&gt; &gt; According to git bisect run, the commit which introduced this problem is:<br>
&gt; &gt;<br>
&gt; &gt; 837422858c2e4ab447879a4141361fd382645406<br>
&gt; &gt; commit 837422858c2e4ab447879a4141361fd382645406<br>
&gt; &gt; Author: Anand Avati &lt;<a href="mailto:avati@redhat.com">avati@redhat.com</a>&gt;<br>
&gt; &gt; Date:   Thu Nov 21 06:48:17 2013 -0800<br>
&gt; &gt;<br>
&gt; &gt;      core: fix errno for non-existent GFID<br>
&gt; &gt;<br>
&gt; &gt;      When clients refer to a GFID which does not exist, the errno to<br>
&gt; &gt;      be returned in ESTALE (and not ENOENT). Even though ENOENT might<br>
&gt; &gt;      look &quot;proper&quot; most of the time, as the application eventually expects<br>
&gt; &gt;      ENOENT even if a parent directory does not exist, not returning<br>
&gt; &gt;      ESTALE results in resolvers (FUSE and GFAPI) to not retry resolution<br>
&gt; &gt;      in uncached mode. This can result in spurious ENOENTs during<br>
&gt; &gt;      concurrent path modification operations.<br>
&gt; &gt;<br>
&gt; &gt;      Change-Id: I7a06ea6d6a191739f2e9c6e333a1969615e05936<br>
&gt; &gt;      BUG: 1032894<br>
&gt; &gt;      Signed-off-by: Anand Avati &lt;<a href="mailto:avati@redhat.com">avati@redhat.com</a>&gt;<br>
&gt; &gt;      Reviewed-on: <a href="http://review.gluster.org/6322" target="_blank">http://review.gluster.org/6322</a><br>
&gt; &gt;      Tested-by: Gluster Build System &lt;<a href="mailto:jenkins@build.gluster.com">jenkins@build.gluster.com</a>&gt;<br>
&gt; &gt;<br>
&gt; &gt; Affected branches: master, 3.5, 3.4,<br>
&gt; &gt;<br>
&gt; &gt; Will be working with Venkatesh to get a fix for this on all these branches.<br>
&gt; &gt; Good catch venkatesh!!. Thanks a lot for a simple case to re-create the<br>
&gt; &gt; issue :-).<br>
&gt;<br>
&gt; Thanks for the analysis, Pranith &amp; Venkatesh! Let us make sure that we<br>
&gt; add this test case to our regression tests.<br>
&gt;<br>
&gt; &gt;<br>
&gt; &gt; Vijay,<br>
&gt; &gt;       Do you think we need this patch for 3.4 as well? Did we get enough<br>
&gt; &gt;       baking time? The change seems delicate. In the sense that all the<br>
&gt; &gt;       places which are expecting ENOENT need to be carefully examined.<br>
&gt; &gt;       Even if we miss one place, we have a potential bug.<br>
&gt;<br>
&gt;<br>
&gt; We would need to fix this in 3.4 failing which we will end up with a<br>
&gt; regression from 3.4.1. For 3.4.2, we have two options:<br>
&gt;<br>
&gt; 1. Revert the original commit<br>
&gt;<br>
&gt; 2. Fix this problem<br>
<br>
</div></div>If we fix this problem, we will only be fixing this particular problem. We<br>
don&#39;t know if there are more similar issues. That is the reason I am a bit<br>
concerned about the nature of change introduced by the original commit.<br>
<span class="HOEnZb"><font color="#888888"><br>
Pranith<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
&gt;<br>
&gt; I think we can reach a decision after you post a fix. We can base our<br>
&gt; decision on the complexity/intrusiveness of the new patch.<br>
&gt;<br>
&gt; -Vijay<br>
&gt;<br>
&gt;<br>
&gt;<br>
&gt;<br>
<br>
_______________________________________________<br>
Gluster-devel mailing list<br>
<a href="mailto:Gluster-devel@nongnu.org">Gluster-devel@nongnu.org</a><br>
<a href="https://lists.nongnu.org/mailman/listinfo/gluster-devel" target="_blank">https://lists.nongnu.org/mailman/listinfo/gluster-devel</a><br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr"><i style="font-family:arial;font-size:small">Religious confuse piety with mere ritual, the virtuous confuse regulation with outcomes</i><br>
</div>
</div>