I have a strange issue I haven't seen before. I have a ZFS volume which reports it's about 1.7Gb in size, and so does a snapshot. If I then try to do a zfs send for backup purposes, I get a HUGE file - My automated backup, gzipped, results in a 12Gb file, and when I did a test just now (without gzip) I aborted after the file grew to 66Gb - which indicates there is a LOT of repeated data. What's going on here? Fragmentation? If so, what to do?
# zpool list NAME SIZE ALLOC FREE EXPANDSZ FRAG CAP DEDUP HEALTH ALTROOT lxd 476G 64.8G 411G - 60% 13% 1.00x ONLINE -
# zfs list NAME USED AVAIL REFER MOUNTPOINT lxd 64.8G 396G 24K none ... lxd/containers/cdinspector 993M 1.32G 1.68G /var/snap/lxd/common/lxd/storage-pools/lxd/containers/cdinspector
# zfs list -t snapshot NAME USED AVAIL REFER MOUNTPOINT lxd/containers/cdinspector@test 1.39M - 1.68G -
# zfs list -r lxd/containers/cdinspector NAME USED AVAIL REFER MOUNTPOINT lxd/containers/cdinspector 1.05G 1.31G 1.69G /var/snap/lxd/common/lxd/storage-pools/lxd/containers/cdinspector
Command used to stream the volume:
# zfs send lxd/containers/cdinspector@test | /usr/bin/mbuffer -m 500M > /backup/test