Whamcloud - gitweb
LU-11867 osd-ldiskfs: FID in LMA mismatch won't block create 35/37135/3
authorLai Siyao <lai.siyao@whamcloud.com>
Mon, 7 Jan 2019 03:37:48 +0000 (11:37 +0800)
committerOleg Drokin <green@whamcloud.com>
Fri, 17 Jan 2020 20:14:15 +0000 (20:14 +0000)
commit3b80f5c0217f7a04e852bc47f7beb913c5f9842b
tree05b629196a49cf1e2b895d9c36fffdffb2ff5fab
parent9ede55bc906fd033ccb9f40fb0a6a625e836bef3
LU-11867 osd-ldiskfs: FID in LMA mismatch won't block create

Sometimes two OST objects may be mapped to the same inode, so the
second object FID mismatch with FID in inode LMA, in this case,
if this inode was not written yet, it's safe to set object inode
to NULL to let it create a new inode.

Another case is if the mapped inode doesn't exist, it's also safe
to not initialize inode and return 0, so that create can succeed.

Add sanity-scrub.sh 4d for this.

Lustre-change: https://review.whamcloud.com/34052
Lustre-commit: cbf59ba6a56086c53a15622db7fa9f95d9798b7f

Signed-off-by: Lai Siyao <lai.siyao@whamcloud.com>
Change-Id: Ic84cdeaca2ea202ab0c01a0075a2f9ee8627f508
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Li Xi <lixi@ddn.com>
Signed-off-by: Minh Diep <mdiep@whamcloud.com>
Reviewed-on: https://review.whamcloud.com/37135
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/include/obd_support.h
lustre/osd-ldiskfs/osd_handler.c
lustre/tests/sanity-scrub.sh