[Top][All Lists]

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

bug#48164: cp --reflink=never no longer works as expected

From: Pádraig Brady
Subject: bug#48164: cp --reflink=never no longer works as expected
Date: Sun, 2 May 2021 21:59:21 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:84.0) Gecko/20100101 Thunderbird/84.0

On 02/05/2021 18:12, Chris Murphy wrote:

Fedora 34 user 'adrum' reports that 'cp --reflink=never' is performing
a lightweight copy on Btrfs. And filefrag -v shows the extents are
shared. Strace shows use of copy_file_range even with --reflink=never

The note for copy_file_range() includes:

copy_file_range() gives filesystems an opportunity to implement
        "copy acceleration" techniques, such as the use of reflinks

Downstream bug

The commit that causes the change in behavior:

It references five upstream commits.

Thanks for the detailed report. I've fixed this upstream with:
Ideally copy_file_range() would take CAN_REFLINK as a flag,
but for now the patch above avoids the call with --reflink=never.

Note we've not released an official coreutils release with this change yet,
as we've yet to fully test all variations of this new copying logic.
There are subtle interactions like this that need to be considered.
BTW there has been recent discussions on the non generality of
copy_file_range() at https://lwn.net/Articles/846403/

Marking this as done.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]