From d3d973a841cf44f1833d47aed5354762f46f7351 Mon Sep 17 00:00:00 2001 From: Andreas Dilger Date: Thu, 2 May 2013 22:05:48 -0600 Subject: [PATCH] LU-1993 llite: debugging for ll_file_open LASSERT 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 Change-Id: Ie03f706bcb32b03d94c84c5d80dae197813ebbe5 Reviewed-on: http://review.whamcloud.com/6250 Tested-by: Jenkins Reviewed-by: Bob Glossman Tested-by: Maloo Reviewed-by: John L. Hammond Reviewed-by: Oleg Drokin --- lustre/llite/file.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/lustre/llite/file.c b/lustre/llite/file.c index e2eb565..cd7877c 100644 --- a/lustre/llite/file.c +++ b/lustre/llite/file.c @@ -669,16 +669,18 @@ restart: * (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; -- 1.8.3.1