This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vstinner
Recipients giampaolo.rodola, pablogsal, vstinner
Date 2019-06-04.21:51:31
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1559685091.83.0.518908232506.issue37157@roundup.psfhosted.org>
In-reply-to
Content
Random notes.

Extract of Linux manual page of "cp":

       --reflink[=WHEN]
              control clone/CoW copies. See below


       When --reflink[=always] is specified, perform a lightweight copy, where
       the data blocks are copied only when modified.  If this is not possible
       the copy fails, or if --reflink=auto is specified, fall back to a stan‐
       dard copy.  Use --reflink=never to ensure a standard copy is performed.

--

"Why is cp --reflink=auto not the default behaviour?":
https://unix.stackexchange.com/questions/80351/why-is-cp-reflink-auto-not-the-default-behaviour

--

reflinks are supported by BTRFS and OCFS2.

XFS seems to have an experimental support for reflink, 2 years old article:
https://strugglers.net/~andy/blog/2017/01/10/xfs-reflinks-and-deduplication/

Linux version of ZFS doesn't support reflink yet:
https://github.com/zfsonlinux/zfs/issues/405

--

Python binding using cffi to get reflink:
https://gitlab.com/rubdos/pyreflink
"Btrfs, XFS, OCFS2 reflink support. Btrfs is tested the most.
Apple macOS APFS clonefile support. Little testing, be careful. It might eat data."

--

"reflink for Windows":
https://github.com/0xbadfca11/reflink
"Windows Server 2016 introduce Block Cloning feature."
=> https://docs.microsoft.com/en-us/windows-server/storage/refs/block-cloning


"ReFS v2 is only available in Windows Server 2016 and Windows 10 version 1703 (build 15063) or later.
Windows 10 version 1607 (build 14393) and earlier Windows only can use ReFS v1."

--

Linux has 2 ioctl:

       #include <sys/ioctl.h>
       #include <linux/fs.h>

       int ioctl(int dest_fd, FICLONERANGE, struct file_clone_range *arg);
       int ioctl(int dest_fd, FICLONE, int src_fd);

http://man7.org/linux/man-pages/man2/ioctl_ficlonerange.2.html
History
Date User Action Args
2019-06-04 21:51:31vstinnersetrecipients: + vstinner, giampaolo.rodola, pablogsal
2019-06-04 21:51:31vstinnersetmessageid: <1559685091.83.0.518908232506.issue37157@roundup.psfhosted.org>
2019-06-04 21:51:31vstinnerlinkissue37157 messages
2019-06-04 21:51:31vstinnercreate