Whamcloud - gitweb
LU-10155 recovery: support setstripe replay 04/30704/8
authorLai Siyao <lai.siyao@intel.com>
Thu, 4 Jan 2018 01:38:43 +0000 (09:38 +0800)
committerOleg Drokin <oleg.drokin@intel.com>
Wed, 31 Jan 2018 05:52:11 +0000 (05:52 +0000)
commit3a0a50f44f68066642a23365fa4a6f1924dd1108
tree22e93d42fa9af810defc49f63b799cfa22331b0e
parentf1daa8fc6575e5b9e4a2f1f2ae4ceaefb889a694
LU-10155 recovery: support setstripe replay

Regular file open will always reserve space for LOV ea, which is used
to store user specified lov_user_md, or lov_mds_md for replay, but if
this open is the first open in 'lfs setstripe', it doesn't have
lov_user_md specified, or lov_mds_md for replay because
O_LOV_DELAY_CREATE is set, but MDT will treat the EA field in the
request as valid one, so fails in magic check in this open replay.

This patch fixes this issues on both sides:
1. client doesn't reserve space for LOV ea in
   open(O_LOV_DELAY_CREATE), this change is not necessary, but to
   make clean of the code.
2. server doesn't create OST objects for open(O_LOV_DELAY_CREATE)
   replay.

Add setstripe/setdirstripe replay test in replay-single.sh, which
are 2c, 2d.

Signed-off-by: Lai Siyao <lai.siyao@intel.com>
Change-Id: Ia7971523710822308328239f36f7d690314e0e45
Reviewed-on: https://review.whamcloud.com/30704
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Mike Pershin <mike.pershin@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/mdc/mdc_locks.c
lustre/mdd/mdd_dir.c
lustre/tests/replay-single.sh