linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Why so much "btrfs send" data for "cp -a --reflink"?
@ 2020-10-05  7:54 Torsten Bronger
  2020-10-06 12:48 ` Torsten Bronger
  0 siblings, 1 reply; 4+ messages in thread
From: Torsten Bronger @ 2020-10-05  7:54 UTC (permalink / raw)
  To: linux-btrfs

Hallöchen!

I have two subvolumes A and B.  „A“ contains 50GB data, B is empty.
None is a snapshot of the other.  Now, I copy all data from A to B
with "cp -a --reflink A/* B".  This copying takes less than a
second.  So apparently, no bulk data was duplicated.  "diff -rq A B"
is empty.  So far, so good.

However, it surprises me that

    btrfs send -p A B | wc -c

reports 12GB.  I would have hoped for very few data (say, a couple
of MBs).  Or, the whole 50GB (because A is not a real parent of B,
and never has been).  An additional "-c A" does not change anything.

Why is this?  In other words, what comprises those 12GB?

It may be insignificant, but the 50GB are almost fully a single
VirtualBox .vdi file, somewhat fragmented (filefrag says 16000).

Regards,
Torsten.

-- 
Torsten Bronger


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-10-06 15:41 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-10-05  7:54 Why so much "btrfs send" data for "cp -a --reflink"? Torsten Bronger
2020-10-06 12:48 ` Torsten Bronger
2020-10-06 13:34   ` Filipe Manana
2020-10-06 15:39     ` Torsten Bronger

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).