Whamcloud - gitweb
LU-3230 osp: unstick precreates on unmount 95/7995/13
authorNathaniel Clark <nathaniel.l.clark@intel.com>
Fri, 1 Nov 2013 12:52:14 +0000 (08:52 -0400)
committerOleg Drokin <oleg.drokin@intel.com>
Mon, 2 Dec 2013 13:25:22 +0000 (13:25 +0000)
Allow osp_precreate_reserve to propagate error, Add debug code to
illuminate what the error code is if not EIO.

Test-Parameters: mdsfilesystemtype=zfs mdtfilesystemtype=zfs ostfilesystemtype=zfs
Test-Parameters: mdsfilesystemtype=zfs mdtfilesystemtype=zfs ostfilesystemtype=zfs mdscount=3
Signed-off-by: Nathaniel Clark <nathaniel.l.clark@intel.com>
Change-Id: I1c15375d5e50d5a47a72b6c3c8e27512f51c3f9c
Reviewed-on: http://review.whamcloud.com/7995
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Johann Lombardi <johann.lombardi@intel.com>
lustre/osp/osp_precreate.c

index 20783fc..4bd43d3 100644 (file)
@@ -1010,8 +1010,16 @@ static int osp_precreate_ready_condition(const struct lu_env *env,
                return 1;
 
        /* Bail out I/O fails to OST */
-       if (d->opd_pre_status == -EIO)
+       if (d->opd_pre_status != 0 &&
+           d->opd_pre_status != -EAGAIN &&
+           d->opd_pre_status != -ENODEV &&
+           d->opd_pre_status != -ENOSPC) {
+               /* DEBUG LU-3230 */
+               if (d->opd_pre_status != -EIO)
+                       CERROR("%s: precreate failed opd_pre_status %d\n",
+                              d->opd_obd->obd_name, d->opd_pre_status);
                return 1;
+       }
 
        return 0;
 }