Whamcloud - gitweb
LU-3834 mdt: handle swap_layouts failures during restore 12/9212/2
authorBruno Faccini <bruno.faccini@intel.com>
Tue, 10 Dec 2013 09:55:59 +0000 (10:55 +0100)
committerOleg Drokin <oleg.drokin@intel.com>
Fri, 14 Feb 2014 16:35:28 +0000 (11:35 -0500)
commitcffa2bce7351ddd37ff824ef3c2bd8a7fb7a3239
treeaffc62ea78305b8d026bffdaffe1969b7cf24e21
parent0577bac8e741bf4a1c678fc9e601b2e4d0a21f44
LU-3834 mdt: handle swap_layouts failures during restore

Actually nothing occur after swap_layouts failures during restore,
this can lead to file being left in incoherent state and thus be
unavailable because HS_RELEASED is clear but LOV_PATTERN_F_RELEASED
is still set.
This patch will allow original layout to be recovered by the use of
SWAP_LAYOUTS_MDS_HSM flag. Additionaly this requires HSM xattr of
the data FID to be set.
Also adds layout-swap failure injection and related test.

Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: Id0e9a005362e4a3854b33f6ce1888197d20e7dbf
Reviewed-on: http://review.whamcloud.com/7631
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Aurelien Degremont <aurelien.degremont@cea.fr>
Reviewed-by: jacques-Charles Lafoucriere <jacques-charles.lafoucriere@cea.fr>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/include/obd_support.h
lustre/mdd/mdd_object.c
lustre/mdt/mdt_coordinator.c
lustre/tests/sanity-hsm.sh