Whamcloud - gitweb
LU-11111 lfsck: skip orphan processing 59/32959/20
authorAlexey Lyashkov <c17817@cray.com>
Wed, 8 Aug 2018 04:47:51 +0000 (07:47 +0300)
committerOleg Drokin <green@whamcloud.com>
Mon, 11 Feb 2019 03:24:19 +0000 (03:24 +0000)
commit077570483e75e0610fd45149b926097547c434b8
tree380504156db818868b63f0cf5e3d22af19656bd3
parentbdb2683fffa89ce31f43f5f42eed50e6d6dbb94b
LU-11111 lfsck: skip orphan processing

LFSCK can reconnect a recently-deleted orphan object back
into the normal namespace when it shouldn't.  This can
cause access to the deleted data (potential security risk),
and sometimes cause an assertion if orphan is later deleted.

Skip LFSCK on orphan objects.  Fix the handling of the
LUSTRE_ORPHAN_FL in both osd-zfs and osd-ldiskfs so that
la_valid |= LA_FLAGS is set when la_flags |= LUSTRE_ORPHAN_FL
is set, otherwise the upper layers cannot properly detect it.

Clean up alignment of flags values and provide hex equivalents
so that they are more easily referenced during debugging.

Signed-off-by: Alexey Lyashkov <c17817@cray.com>
Signed-off-by: Andreas Dilger <adilger@whamcloud.com>
Change-Id: I9b2809b95efa4b3c3e3b2c7d0a501624ed743ede
Reviewed-on: https://review.whamcloud.com/32959
Tested-by: Jenkins
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Lai Siyao <lai.siyao@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/include/uapi/linux/lustre/lustre_disk.h
lustre/include/uapi/linux/lustre/lustre_idl.h
lustre/include/uapi/linux/lustre/lustre_user.h
lustre/lfsck/lfsck_engine.c
lustre/mdd/mdd_object.c
lustre/mdd/mdd_orphans.c
lustre/osd-ldiskfs/osd_handler.c
lustre/osd-ldiskfs/osd_scrub.c
lustre/osd-zfs/osd_object.c
lustre/osd-zfs/osd_scrub.c
lustre/tests/sanity-lfsck.sh