On Jun 15, 2011, at 4:45 AM, Darren J Moffat wrote:

> On 06/15/11 12:29, Edward Ned Harvey wrote:
>>> From: zfs-discuss-boun...@opensolaris.org [mailto:zfs-discuss-
>>> boun...@opensolaris.org] On Behalf Of Richard Elling
>>> 
>>> That would suck worse.
>> 
>> Don't mind Richard.  He is of the mind that ZFS is perfect for everything
>> just the way it is, and anybody who wants anything different should adjust
>> their thought process.

ouch

> 
> I suspect rather than that it is more that Richard equated "write" to 
> write(2) / dmu_write() calls and that would suck performance wise.

Yep, especially because you also have to write the metadata that said when you
wrote, and so on.

> 
> I also suspect that what Simon wants isn't a snapshot of every little 
> write(2) level call but when the file is completed being updated, maybe on 
> close(2) [ but that assumes the app does actually call close() ].
> 
>> I know I've certainly had many situations where people wanted to snapshot or
>> rev individual files everytime they're modified.  As I said - perfect
>> example is Google Docs.  Yes it is useful.  But no, it's not what ZFS does.
> 
> Exactly versions of a whole file, but that is different to a snapshot on 
> every write.

Yes, and as others have said, the appropriate interface is critical. A WebDAV 
PUT does have
a bounded endpoint where version control makes sense. An mmap(2) does not. 
Adding a call
to zfs snapshot when a WedDAV PUT completes seems trivial. But you could also 
call a traditional
source code control system check-in as well. Before long, you can have a useful 
CMS system.

There are a large number of programs that are designed to not close files, and 
it will be difficult 
to derive meaningful snapshot opportunities in those cases.

> How you interpret "on every write" depends on where in the stack you are 
> coming from.  If you think about an application a "write" is whey you save 
> the document but at the ZPL layer that is multiple write(2) calls and maybe 
> even some rename(2)/unlink(2)/close(2) calls as well.
> If you move further down then doing a snapshot on every dmu_write() call is 
> fundamentally at odds with how ZFS works.

Yep.
 -- richard

_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

Reply via email to