Whamcloud - gitweb
LU-2523 mdt: handle -ENOENT && !MDS_OPEN_CREAT in reint open
authorJohn L. Hammond <john.hammond@intel.com>
Wed, 27 Feb 2013 07:12:39 +0000 (01:12 -0600)
committerOleg Drokin <oleg.drokin@intel.com>
Wed, 13 Mar 2013 06:05:53 +0000 (02:05 -0400)
commitdfe7fcd415fa40e2ab059c5201f7df4e2e174e54
tree67eb0ca3d243a19d570c95b0f0f365439f98b98d
parentc88317218461159cae399f74b459a850ae3c84f8
LU-2523 mdt: handle -ENOENT && !MDS_OPEN_CREAT in reint open

If mdt_open_by_fid_lock() returns -ENOENT and MDS_OPEN_CREAT is not
set in create flags then bail out and return -ENOENT from
mdt_reint_open().  In mdt_open_by_fid_lock() if -ENOENT is returned
then ensure that DISP_IT_EXECD is set in the reply disposition.  Add
sanity test_27B to call the LL_IOC_LOV_SETSTRIPE ioctl() on an open
unlinked file, a situation which triggers the first case.  In sanityn
test 30, remote the requirement that opening an unlinked file via
/proc/PID/exe return -ESTALE.  In racer's file_create.sh, reinstate
the call to 'lfs setstripe' before dd is started, effectively
reverting commit 0be1c87fe2d4ffddaca9e568cc137518b7368b2d.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
Change-Id: I74e2297c4210ff18acbf60efdf51049d9a88cbea
Reviewed-on: http://review.whamcloud.com/5417
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Tested-by: Hudson
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/mdt/mdt_open.c
lustre/tests/multiop.c
lustre/tests/racer/file_create.sh
lustre/tests/sanity.sh
lustre/tests/sanityn.sh