Whamcloud - gitweb
LU-13437 mdt: don't fetch LOOKUP lock for remote object 61/38561/9
authorLai Siyao <lai.siyao@whamcloud.com>
Sun, 10 May 2020 07:22:36 +0000 (15:22 +0800)
committerOleg Drokin <green@whamcloud.com>
Tue, 23 Jun 2020 08:12:02 +0000 (08:12 +0000)
commitf9a2da63abab5b8b687842166a0b5b5e434ad441
treec70ecb11be3fe02d5a622af3426a3845206e19e8
parente1bf37870d8654d24a1e49a1822bb02aa97a6672
LU-13437 mdt: don't fetch LOOKUP lock for remote object

Pack parent FID in getattr by FID, which will be used to check whether
child is remote object on parent. The helper function is called
mdt_is_remote_object(). NB, directory shard is not treated as remote
object, because if so, client needs to revalidate shards when dir is
accessed, which will hurt performance much.

For getattr by FID, if object is remote file on parent, don't fetch
LOOKUP lock, otherwise client may see stale dir entries.

Signed-off-by: Lai Siyao <lai.siyao@whamcloud.com>
Change-Id: Id181ecc053579ee394080381a82706334503ced0
Reviewed-on: https://review.whamcloud.com/38561
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Yingjin Qian <qian@ddn.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/include/obd.h
lustre/include/obd_class.h
lustre/llite/file.c
lustre/llite/llite_lib.c
lustre/lmv/lmv_intent.c
lustre/lmv/lmv_internal.h
lustre/lmv/lmv_obd.c
lustre/mdt/mdt_handler.c
lustre/mdt/mdt_internal.h
lustre/mdt/mdt_lib.c