Re: [PATCH v2 2/4] overlay: fix exit code for some fsck.overlay valid cases

[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]



On Tue, Oct 16, 2018 at 10:32 AM zhangyi (F) <yi.zhang@xxxxxxxxxx> wrote:
>
> Some valid test cases about fsck.overlay may be not valid enough now,
> they lose the impure xattr on the parent directory of the simluated
> redirect directory, and lose the whiteout which use to cover the origin
> lower object. Then fsck.overlay will fix these two inconsistency which
> are not those test cases want to cover, thus it will lead to
> fsck.overlay return FSCK_NONDESTRUCT instead of FSCK_OK. Fix these by
> complement the missing overlay related features.
>
> Signed-off-by: zhangyi (F) <yi.zhang@xxxxxxxxxx>
> ---

Ok. I think it's fine if we merge this fix now, but this way it is going
to be quite hard to maintain this test.

Imagine every time that you add another feature to fsck.overlay,
say "add overlay features xattr", fsck will start returning FSCK_NONDESTRUCT
and break this test.

Perhaps it would have been better to construct the test cases by:
- mount overlay
- create some copied up/ redirected  dirs and whiteouts
- umount overlay
- make minor modifications to upper/lower layer
- run fsck

Then you wouldn't need to worry about things like impure parent dir
and future overlay features.

I will leave it to you to decide if you want to fix this now or the
next time around...

Thanks,
Amir.



[Index of Archives]     [Linux Filesystems Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux