On 10-Apr-09, at 2:03 PM, Harry Putnam wrote:

David Magda <dma...@ee.ryerson.ca> writes:

On Apr 7, 2009, at 16:43, OpenSolaris Forums wrote:

if you have a snapshot of your files and rsync the same files again,
you need to use "--inplace" rsync option , otherwise completely new
blocks will be allocated for the new files. that`s because rsync
will write entirely new file and rename it over the old one.


not sure if this applies here, but i think it`s worth mentioning and
not obvious.....

With ZFS new blocks will always be allocated: it's copy-on-write (COW)
file system.

So who is right here...

As far as I can see - the effect of --inplace would be that new blocks are allocated for the deltas, not the whole file, so Daniel Rock's finding does not contradict "OpenSolaris Forums". But in either case, COW is involved.

--Toby

Daniel Rock says he can see on disk that it
doesn't work that way... that is only a small amount of space is taken
when rsyncing in this way.
See his post:

  From: Daniel Rock <sola...@deadcafe.de>
  Subject: Re: Data size grew.. with compression on
  Newsgroups: gmane.os.solaris.opensolaris.zfs
  To: zfs-discuss@opensolaris.org
  Date: Thu, 09 Apr 2009 16:35:07 +0200
  Message-ID: <49de079b.2040...@deadcafe.de>

  [...]

  Johnathon wrote:
ZFS will allocate new blocks either way

  Daniel R replied: No it won't. --inplace doesn't rewrite blocks
  identical on source and target but only blocks which have been
  changed.

  I use rsync to synchronize a directory with a few large files (each
  up to 32 GB). Data normally gets appended to one file until it
  reaches the size limit of 32 GB. Before I used --inplace a snapshot
  needed on average ~16 GB. Now with --inplace it is just a few
  kBytes.


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

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

Reply via email to