Description of problem: cp --reflink=never creates shared extents Version-Release number of selected component (if applicable): coreutils-8.32-23.fc34.x86_64 How reproducible: Always Steps to Reproduce: 1. cp --reflink=never a b 2. filefrag -v a; filefrag -v b 3. Actual results: a and b share all extents Expected results: They should not be reflink copies Additional info: Just a guess but when I strace the command using --reflink=never I see: copy_file_range(3, NULL, 4, NULL, 9223372035781033984, 0) = 65843200 copy_file_range(3, NULL, 4, NULL, 9223372035781033984, 0) = 0 And I see in the change log: * Wed Mar 24 2021 Kamil Dudka <kdudka> - 8.32-20 - cp: use copy_file_range if available So I wonder if there isn't a reflink=never exception to that change?
Created attachment 1778596 [details] strace cp --reflink=never
Problem does not happen with coreutils-8.32-19.fc34.x86_64.rpm coreutils-common-8.32-19.fc34.x86_64.rpm Problem does happen with coreutils-8.32-20.fc34.x86_64.rpm coreutils-common-8.32-20.fc34.x86_64.rpm
Upstream bug report: https://lists.gnu.org/archive/html/bug-coreutils/2021-05/msg00001.html
Thank you for debugging it and reporting it upstream! We need to backport the following upstream commit to fix it: https://git.savannah.gnu.org/gitweb/?p=coreutils.git;a=commitdiff;h=v8.32-147-gea9af9923
dist-git commits: https://src.fedoraproject.org/rpms/coreutils/c/3a336cf37e1ded55f6c9c835ea527074a4e876e0?branch=rawhide https://src.fedoraproject.org/rpms/coreutils/c/5985282d0541a9db2c0de830bbafceea8dcbeed2?branch=f34
FEDORA-2021-893a614857 has been submitted as an update to Fedora 34. https://bodhi.fedoraproject.org/updates/FEDORA-2021-893a614857
FEDORA-2021-893a614857 has been pushed to the Fedora 34 testing repository. Soon you'll be able to install the update with the following command: `sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2021-893a614857` You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2021-893a614857 See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.
FEDORA-2021-893a614857 has been pushed to the Fedora 34 stable repository. If problem still persists, please make note of it in this bug report.