Pádraig Brady <[email protected]> writes:

> On 02/09/2026 20:47, Paul Eggert wrote:
>> On 2026-09-02 10:12, Pádraig Brady wrote:
>>> we should remove ENOSPC from being considered as a terminal error
>> Yes, but it's not just ENOSPC; it's also EDQUOT etc. That is, as far
>> as I can see, no error from an allocation group necessarily means
>> there must be an error from an ordinary read+write copy.
>
> Don't we need to be careful with some errors as per
> https://github.com/coreutils/coreutils/commit/f6c93f334
> https://bugs.gnu.org/60489 ?
>
> Also this removes partially cloned files on error,
> rather than just empty files. ?

Perhaps it is best to use your relatively conservative change of
ignoring ENOSPC and maybe EDQUOT, and discuss the further changes post
release. Since ENOSPC seems to have a case that is frequently
reproducible (Thanks Peter and colleagues for the detailed
investigation).

Off topic, but I wasn't really aware partial reflinks were a thing. Now
I see FICLONERANGE exists [1]. BTRFS documents [2]:

    The reflink is typically meant for whole files but a partial file
    range can be also copied, though there are no ready-made tools for
    that.

A future idea for 'dd' maybe. Not the default though, of course.

Collin

[1] https://man7.org/linux/man-pages/man2/ioctl_ficlone.2.html
[2] https://btrfs.readthedocs.io/en/latest/Reflink.html



Reply via email to