[Nottingham] Copy without copying?

VM vadim at mankevich.co.uk
Fri Jun 7 16:13:27 UTC 2019


well, a simple lvm snapshot would work that way, but you'd have to create a new volume group etc. and make sure its size is sufficient for syoring all changed blocks.


On June 7, 2019 3:47:19 PM UTC, J J via Nottingham <nottingham at mailman.lug.org.uk> wrote:
>Thanks for the tips. Overlay is deffo an improvement as it will only
>take a
>copy of a file if there is a change but it's still a full copy of the
>entire file.
>I am wondering if there's a way that XFS, ZFS or whatever can do
>something
>even deeper and maintain partial/block differences or something.
>
>On Fri, 7 Jun 2019 at 16:25, Andy Smith via Nottingham <
>nottingham at mailman.lug.org.uk> wrote:
>
>> Hello,
>>
>> On Fri, Jun 07, 2019 at 03:12:21PM +0100, J J via Nottingham wrote:
>> > With Ext4, is there some magic way I can create and ad hoc
>"differencing
>> > volume" that appear to be like a copy but isn't. The tests can do
>what
>> they
>> > like and that the whole thing gets chucked.
>> > i.e. avoiding the copy operation
>>
>> You already found overlayfs. Another possible answer is btrfs or
>> xfs, which support copy on write.
>>
>> By using either of those you can do cp --reflink=always … and it
>> will do a copy that only adds a reference to the source, not an
>> actual copy of the data. This uses no additional space. If you alter
>> one of the copies then the link is broken.
>>
>> And of course btrfs also has writeable snapshots.
>>
>> Cheers,
>> Andy
>>
>> --
>> https://bitfolk.com/ -- No-nonsense VPS hosting
>>
>> --
>> Nottingham mailing list
>> Nottingham at mailman.lug.org.uk
>> https://mailman.lug.org.uk/mailman/listinfo/nottingham

--
vadim at mankevich.co.uk PGP key fingerprint
0xC046022A3A91455AF0C9BB2404BF882B1905C772
Retrieve from https://keybase.io/vmankevich

"When we take away the right to figure out if something bad is going on in our computers, the inevitable consequence is that bad things will happen in our computers." (Cory Doctorow)




More information about the Nottingham mailing list