Whamcloud - gitweb
LU-15830 mdt: mkdir to lookup target name
authorAlex Zhuravlev <bzzz@whamcloud.com>
Fri, 6 May 2022 06:49:56 +0000 (09:49 +0300)
committerOleg Drokin <green@whamcloud.com>
Thu, 12 May 2022 15:46:17 +0000 (11:46 -0400)
distributed mkdir should lookup the target name to
avoid rollback as much as possible as the latter is
very expensive due to llog re-initialization.

Signed-off-by: Alex Zhuravlev <bzzz@whamcloud.com>
Change-Id: If28760e0afb804dca11e1e7501e0a53ff9067ca1
Reviewed-on: https://review.whamcloud.com/47226
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Lai Siyao <lai.siyao@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/mdt/mdt_reint.c

index ab3cdd4..c800ca6 100644 (file)
@@ -626,6 +626,8 @@ static int mdt_create(struct mdt_thread_info *info)
         * not exist.
         */
        info->mti_spec.sp_cr_lookup = 0;
+       if (mdt_object_remote(parent))
+               info->mti_spec.sp_cr_lookup = 1;
        info->mti_spec.sp_feat = &dt_directory_features;
 
        rc = mdo_create(info->mti_env, mdt_object_child(parent), &rr->rr_name,