> On Jun 26, 2017, at 22:45, Quincey Morris 
> <quinceymor...@rivergatesoftware.com> wrote:
> 
>> On Jun 26, 2017, at 19:17 , Sandor Szatmari <admin.szatmari....@gmail.com> 
>> wrote:
>> 
>> Are you talking about just a regular old copy or a copy in the sense of a 
>> time machine backup?  Are these behaviors different on APFS?
> 
> Yes and no. A regular old copy will create metadata for a new file, and point 
> back to the data blocks of the copied file. A time machine backup will create 
> a snapshot, which is effect a copy of all the metadata in the volume, with 
> the same shared pointers to the data blocks.

Yes, I felt the description of the copy on write behavior was intended to be 
universal to all copy operations not just a special operation reserved for time 
machine.  But, my even more admittedly vague understanding did not allow me to 
confidently draw a distinction be tween the two.  Thank you for tipping the 
scales.

> 
> In both cases, the functionality relies on the copy-on-write behavior, which 
> works at the data block level, not the file level.
Yes, this is very nice...
> (The latter point is worth keeping in mind, because it means that deleting 
> files in APFS may not recover all of the file’s size into free space.)
The ADC video stresses this point several times.

> 
>> On Jun 26, 2017, at 19:38 , Rick Mann <rm...@latencyzero.com> wrote:
>> 
>> But there's actually a POSIX "clone" API, and so I wonder if a copy is 
>> different from a clone.
> 
> My (admittedly vague) understanding is that all file system copy operations 
> are expected to be clones. I would imagine the difference between the APIs to 
> be that a “copy" will do a traditional duplication if the source file is 
> uncloneable (e.g. on a non-APFS volume), but the “clone” would fail.
> 
> But it would be a big hole if existing apps that copy items didn’t get the 
> cloning behavior by default.
> 
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to