Create remote update llog object synchronously, so
it will make sure the llog object exists, before
the cross-MDT operations will write any update llog
records.
Signed-off-by: wang di <di.wang@intel.com>
Change-Id: I690e94e68b8b64dfe94412f58448f3867f61ff3e
Reviewed-on: http://review.whamcloud.com/15278
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Alex Zhuravlev <alexey.zhuravlev@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
if (IS_ERR(th))
GOTO(out, rc = PTR_ERR(th));
+ /* Create the remote update llog object synchronously, which
+ * happens during inialization process see lod_sub_prep_llog(),
+ * to make sure the update llog object is created before
+ * corss-MDT writing updates into the llog object */
+ if (dt_object_remote((*res)->lgh_obj))
+ th->th_sync = 1;
+
th->th_wait_submit = 1;
rc = llog_declare_create(env, *res, th);
if (rc == 0) {