Export Virtual Machine in qcow2 format.

Mar 8, 2017
12
0
21
44
Hello,
I should export a virtual machine running in proxmox (version 5.3.12) to do a test and run it on a centos distribution with KVM.
In my old installation of proxmox I found the file of my virtual machine inside the folder /var/lib/vz but with the new version I think the file of the vm isn't present. This is right?
What is the correct way to do it?

thanks a lot

Andrew
 

t.lamprecht

Proxmox Staff Member
Staff member
Jul 28, 2015
4,320
1,081
164
South Tyrol/Italy
shop.maurer-it.com
You can still save them to local (not local-lvm) and have the qcow2 file there, but we now create a thin LVM as then one can do cheap snapshots, and a few other advantages so you probably installed the VM with its disk there.

Anyway, you should be able to see where the VM disk resides through the VMs hardware view, or checking it's config (qm config VMID) on the shell..

With the Volume ID you can then get the path as seen from the host OS to the image and use qemu-img convert to produce a qcow2, e.g.:
Code:
pvesm path VOLUME-ID
qemu-img convert -O qcow2 -f raw INPUT-PATH  OUTPUT.qcow2
 
  • Like
Reactions: supotnickiy

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get your own in 60 seconds.

Buy now!