Move vm with disks on lvm-thin to another server with lvm-thin

Fantu

Active Member
Jan 23, 2024
117
45
28
Hi, I moved vm disks from kvm server (not proxmox) that use raw file to a proxmox mounting a remote folder with it (in my case using smb share but can be done in other ways) and after using qm importdisk directly on the raw files.
Code:
qm importdisk <id vm> /path/image.raw <pve lvm-thin storage> --format raw

Now I'm looking what is the best and faster way to move from a proxmox to another (not cluster), both with vm disks on lvm-thin.
One way is dd to a file in an external disk and after connect to destination server and using "qm importdisk". It is also possible using over the network, without having to attach/detach disks, if you already have enough space on a local partition on one of the servers.
But with vm disks very big is not possible and with this way do a "double" copy with longer time needed.

So to search a way to do a direct copy I found to manually create the destination lv and do a dd over ssh: https://serverfault.com/questions/3...y-from-one-server-to-another-over-the-network.
Is there a better way I didn't found using proxmox (even if not in a cluster) to do it?
 
Last edited:
I haven't tested it yet. But have you ever qm remote-migrate tested it?

Code:
qm help remote-migrate

This makes it possible to migrate entire VMs without a cluster to another Proxmoxhost via the API. And all without ZFS.
 
  • Like
Reactions: Fantu