From: wangdi Date: Fri, 1 Dec 2006 07:40:45 +0000 (+0000) Subject: Branch:b_new_cmd X-Git-Tag: v1_8_0_110~486^2~50 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=a0d7d23362d17c8e0a9504bb147474e1739629d2;p=fs%2Flustre-release.git Branch:b_new_cmd Init cat log for mds when add ost in recoverying, to make sure all unlink log can be initialized after config log is processed. This could avoid race beween unlink and llog init postrecovery, which should be the reason of b11218. b:11218 --- diff --git a/lustre/mds/mds_lov.c b/lustre/mds/mds_lov.c index cce6d49..0092e75 100644 --- a/lustre/mds/mds_lov.c +++ b/lustre/mds/mds_lov.c @@ -842,6 +842,15 @@ int mds_notify(struct obd_device *obd, struct obd_device *watched, after the mdt in the config log. They didn't make it into mds_lov_connect. */ rc = mds_lov_update_desc(obd, obd->u.mds.mds_osc_exp); + if (rc) + RETURN(rc); + /* We should update init llog here too for replay unlink and + * possiable llog init race when recovery complete */ + mutex_down(&obd->obd_dev_sem); + llog_cat_initialize(obd, NULL, + obd->u.mds.mds_lov_desc.ld_tgt_count, + &watched->u.cli.cl_target_uuid); + mutex_up(&obd->obd_dev_sem); RETURN(rc); }