btrfs: test that send can issue clone operations within the same file

Verify that both full and incremental send operations can issue
clone operations when a file has extents that are shared with itself
(at different offsets of course).

This currently fails on btrfs but is addressed by a patch for the
kernel titled:

  "Btrfs: send, allow clone operations within the same file"

Signed-off-by: Filipe Manana <fdmanana@suse.com>
Reviewed-by: Eryu Guan <guaneryu@gmail.com>
Signed-off-by: Eryu Guan <guaneryu@gmail.com>
This commit is contained in:
Filipe Manana
2019-11-05 14:57:00 +00:00
committed by Eryu Guan
parent 6fb111ab60
commit cb83673235
3 changed files with 140 additions and 0 deletions
+17
View File
@@ -0,0 +1,17 @@
QA output created by 200
wrote 65536/65536 bytes at offset 0
XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
linked 65536/65536 bytes at offset 65536
XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
wrote 65536/65536 bytes at offset 0
XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
Create a readonly snapshot of 'SCRATCH_MNT' in 'SCRATCH_MNT/base'
At subvol SCRATCH_MNT/base
linked 65536/65536 bytes at offset 65536
XXX Bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
Create a readonly snapshot of 'SCRATCH_MNT' in 'SCRATCH_MNT/incr'
At subvol SCRATCH_MNT/incr
At subvol base
At snapshot incr
OK
OK