From 4b7dbff69a6089410bf76d0a69951611f28d1bb8 Mon Sep 17 00:00:00 2001 From: Dmitry Zogin Date: Fri, 28 May 2010 09:27:34 -0400 Subject: [PATCH] b=21563 Metadata performance has degraded for some operations between 1.6.5 and 1.8.1 Remove the check for OSCC_FLAG_CREATING flag in osc_precreate(), so that it enters oscc_internal_create(). Also remove the check for in oscc_internal_create() for OSCC_FLAG_DEGRADED - let the chance to create objects in case all OSTs are degraded. i=andreas.dilger i=johann --- lustre/osc/osc_create.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/lustre/osc/osc_create.c b/lustre/osc/osc_create.c index b47291f..af96328 100644 --- a/lustre/osc/osc_create.c +++ b/lustre/osc/osc_create.c @@ -197,8 +197,8 @@ static int oscc_internal_create(struct osc_creator *oscc) LASSERT_SPIN_LOCKED(&oscc->oscc_lock); - if ((oscc->oscc_flags & OSCC_FLAG_RECOVERING) || - (oscc->oscc_flags & OSCC_FLAG_DEGRADED)) { + /* Do not check for a degraded OST here - bug21563/bug18539 */ + if (oscc->oscc_flags & OSCC_FLAG_RECOVERING) { spin_unlock(&oscc->oscc_lock); RETURN(0); } @@ -363,8 +363,11 @@ int osc_precreate(struct obd_export *exp) RETURN(0); } - if ((oscc->oscc_flags & OSCC_FLAG_SYNC_IN_PROGRESS) || - (oscc->oscc_flags & OSCC_FLAG_CREATING)) { + /* Do not check for OSCC_FLAG_CREATING flag here, let + * osc_precreate() call oscc_internal_create() and + * adjust oscc_grow_count bug21563 */ + + if (oscc->oscc_flags & OSCC_FLAG_SYNC_IN_PROGRESS) { spin_unlock(&oscc->oscc_lock); RETURN(1); } -- 1.8.3.1