I am searching for a filesystem agnostic method of taking any thin LVM volume, turning it into a file, copying that file to another system and then restoring a still-sparse LVM thin volume
Here are some suggestion I have found but not tried
I don't know if any of these would work or if there's another, better way to do this ?
Here are some suggestion I have found but not tried
Code:
rsync --sparse --progress /dev/pve/vm-600-disk-0 /root/vm-600-sparse.img
rsync --sparse /root/vm-600-sparse.img /dev/pve/vm-600-disk-0
dd if=/dev/pve/vm-600-disk-0 bs=1M status=progress | cp --sparse=always /dev/stdin /root/vm-600-sparse.img
cp --sparse=always /root/vm-600-sparse.img /dev/pve/vm-600-disk-0
qemu-img convert -O raw -p /dev/pve/vm-600-disk-0 /root/vm-600-sparse.img
dd if=/root/vm-600-sparse.img of=/dev/pve/vm-600-disk-0 bs=1M status=progress
I don't know if any of these would work or if there's another, better way to do this ?