Whamcloud - gitweb
LU-14366 mdt: lfs mkdir should return -EEXIST if exists 29/41329/6
authorLai Siyao <lai.siyao@whamcloud.com>
Sat, 23 Jan 2021 10:28:26 +0000 (18:28 +0800)
committerOleg Drokin <green@whamcloud.com>
Thu, 15 Apr 2021 06:30:28 +0000 (06:30 +0000)
commit65e3e4050ec5bb371c1c343fca49a605286a086e
tree6ffe16a55da861dcd441f54431449d4e249299f5
parent886e34ce56c491e8844cf892f32b08807cdf2bff
LU-14366 mdt: lfs mkdir should return -EEXIST if exists

'lfs setdirstripe' will try restripe if target exists, however
it's confusing to get -ENOTSUPP or -EALREADY for 'lfs mkdir', while
the latter invokes the same function as 'lfs setdirstripe'.

Pack MDS_OPEN_CREAT flag in request for 'lfs mkdir', and MDT won't
try restripe if it's set.

Add sanity 230s.

Signed-off-by: Lai Siyao <lai.siyao@whamcloud.com>
Change-Id: I7b7ed04ee0b150253ff4d13bbdf1fe847d8f577c
Reviewed-on: https://review.whamcloud.com/41329
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Yingjin Qian <qian@ddn.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/include/lustre/lustreapi.h
lustre/include/uapi/linux/lustre/lustre_idl.h
lustre/llite/dir.c
lustre/mdc/mdc_lib.c
lustre/mdt/mdt_reint.c
lustre/tests/sanity.sh
lustre/utils/lfs.c
lustre/utils/liblustreapi.c