Whamcloud - gitweb
LU-1993 llite: debugging for ll_file_open LASSERT 50/6250/3
authorAndreas Dilger <andreas.dilger@intel.com>
Fri, 3 May 2013 04:05:48 +0000 (22:05 -0600)
committerOleg Drokin <oleg.drokin@intel.com>
Mon, 18 Nov 2013 12:34:22 +0000 (12:34 +0000)
Add debugging for LASSERTF(it_disposition(it, DISP_ENQ_OPEN_REF)
in ll_file_open(), since this is a rarely hit failure under racer,
and it would be useful to get more information if this is hit
again.  Print the full intent disposition, as well as the status,
in case Oleg's earlier comment about bailing out on any error is
actually the case here.

Test-Parameters: envdefinitions=DURATION=1800 testlist=racer
Signed-off-by: Andreas Dilger <andreas.dilger@intel.com>
Change-Id: Ie03f706bcb32b03d94c84c5d80dae197813ebbe5
Reviewed-on: http://review.whamcloud.com/6250
Tested-by: Jenkins
Reviewed-by: Bob Glossman <bob.glossman@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/llite/file.c

index e2eb565..cd7877c 100644 (file)
@@ -669,16 +669,18 @@ restart:
                  * (bug 3430) */
                 /* XXX (green): Should not we bail out on any error here, not
                  * just open error? */
                  * (bug 3430) */
                 /* XXX (green): Should not we bail out on any error here, not
                  * just open error? */
-                rc = it_open_error(DISP_OPEN_OPEN, it);
-                if (rc)
-                        GOTO(out_och_free, rc);
+               rc = it_open_error(DISP_OPEN_OPEN, it);
+               if (rc != 0)
+                       GOTO(out_och_free, rc);
 
 
-                LASSERT(it_disposition(it, DISP_ENQ_OPEN_REF));
+               LASSERTF(it_disposition(it, DISP_ENQ_OPEN_REF),
+                        "inode %p: disposition %x, status %d\n", inode,
+                        it_disposition(it, ~0), it->d.lustre.it_status);
 
 
-                rc = ll_local_open(file, it, fd, *och_p);
-                if (rc)
-                        GOTO(out_och_free, rc);
-        }
+               rc = ll_local_open(file, it, fd, *och_p);
+               if (rc)
+                       GOTO(out_och_free, rc);
+       }
        mutex_unlock(&lli->lli_och_mutex);
         fd = NULL;
 
        mutex_unlock(&lli->lli_och_mutex);
         fd = NULL;