Bug 1971101 - ceph: potential data corruption in cephfs write_begin codepath
Summary: ceph: potential data corruption in cephfs write_begin codepath
Keywords:
Status: VERIFIED
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: kernel
Version: 8.4
Hardware: Unspecified
OS: Unspecified
urgent
unspecified
Target Milestone: beta
: ---
Assignee: Jeff Layton
QA Contact: ymane
John Wilkins
URL:
Whiteboard:
Depends On:
Blocks: 1989301 1996680
TreeView+ depends on / blocked
 
Reported: 2021-06-12 00:22 UTC by Jeff Layton
Modified: 2021-09-01 20:55 UTC (History)
14 users (show)

Fixed In Version: kernel-4.18.0-323.el8
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1996680 (view as bug list)
Environment:
Last Closed:
Type: Bug
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Gitlab redhat/rhel/src/kernel/rhel-8/-/merge_requests/879 0 None None None 2021-06-25 13:40:40 UTC

Description Jeff Layton 2021-06-12 00:22:58 UTC
RHEL 8.4 has an incorrect optimization in the write_begin codepath, such that we could corrupt data if writing to an offset beyond the EOF, but that is within a page that already has data.

There is a fix proposed here that should go into stable kernels v5.10..v5.12. We'll want the same fix for RHEL8.4.z and RHEL8.5.

https://lore.kernel.org/ceph-devel/20210612001141.167797-1-jlayton@kernel.org/T/#mfd7fe6b4251433bd7beb6f49e01fde50f370fc70

Comment 9 Veera Raghava Reddy 2021-07-07 10:48:26 UTC
Hi Yogesh,
Plan for this BZ verification

Comment 10 Jeff Layton 2021-07-07 11:45:57 UTC
I should mention too that there is a new xfstest for this problem:

    https://git.kernel.org/pub/scm/fs/xfs/xfstests-dev.git/commit/?id=80b8fe47d01347d9c5c433440861f41b8954463e

I recommend using that to verify this bug.


Note You need to log in before you can comment on or make changes to this bug.