Convert raw to qcow2

symcbean

Member
May 20, 2020
18
0
6
57
I have several virtual disks (connected to conainers and VMs) in raw format and I want to convert them to qcow2 (I was still learning when I made them!).

Google took me to https://forum.proxmox.com/threads/migrating-from-raw-lvm-to-qcow2.19960/ where someone suggested using the web front end as described here: https://pve.proxmox.com/wiki/Storage_Migration but I can't find my way to that dialog (PVE 6.1-7, no subscription). Migrate only allows me to move to a different machine. Resources -> Edit only allows me to move it different storage, not convert it). It may be relevant that I'm using NFS storage.

If this is unavailable, is the process described by the OP still current?
 
Hi!

"Move disk" should work out. Select the VM and then the "Hardware" tab. Their you should be able to select the Disk and use the "Move Disk" button above.
Screenshot_2020-09-17 alp1 - Proxmox Virtual Environment.png

Clicking that opens a dialog, there select the same (or another) storage, and qcow2 as format.

Note, this only works form VMs, Containers are not supported on .qcow2 images.
 
> Containers are not supported on .qcow2 images.

Ah - that will be where I was going wrong.

Thank you.
 
In my situation (PVE 7.2-11) the button is called Disk Action and has subitems Move Storage, Reassign Owner, and Resize. On Move Storage, the 'Format' field is greyed out:

Screenshot 2022-11-05 at 15.04.13.png
 
  • Like
Reactions: Roopee
you can only write qcow2 files to a FILE SYSTEM. local-lvm is your lvm block provider.

Select a disk store that is based on a local or network file system, eg nfs.
Thank you for your answer. So that means that if I move to qcow2, I cannot move the VM back to local-lvm? And that means that in a standard setup with local-lvm (I just accepted the defaults), snapshotting is by definition not possible?

I admit I am now more confused that I already was.
 
was gonna link that but was beaten to it :)
So that means that if I move to qcow2, I cannot move the VM back to local-lvm?
You can. qcow2 is a file format for a virtual disk; when you use a logical volume provider you dont need the "file" underneath but the functionality the provide (logically) is the same either way. on that same link above, have a look at the "level" column. if it says file, you will need to have the disk as a "file format", eg qcow2. if it says block, you dont.

@proxmox-admin I just noticed that you only have "zfs local" as a filesystem option and "zfs over iscsi" in that table. seems you're missing the most obvious one.
 

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 yours easily in our online shop.

Buy now!