How to Import QCOW2 Images in Proxmox

  • Post author:WunderTech
  • Post published:January 27, 2024
  • Post last modified:May 10, 2024
  • Post category:Proxmox
  • Reading time:7 mins read

Share what you're reading!

QCOW2 is a common disk image that users try to import into Proxmox. QCOW2 disk images are often exported from other types of virtualization software and imported into others, and Proxmox is a common (and versatile) option as a hypervisor. In this article, we’ll look at how to import QCOW2 Images in Proxmox.

How to Import QCOW2 Images in Proxmox

The first step before you can import QCOW2 images in Proxmox is actually having a QCOW2 image. This means you’ll generally have to export it from a different virtualization server and have it accessible in Proxmox.

You can either move the image to the Proxmox hypervisor or have it on a shared resource like an NFS share on a NAS (step 1 of this Proxmox backup tutorial). As soon as the image is accessible in Proxmox, you can start the process below to import.

1. The easiest way to import a QCOW2 image is to create a blank virtual machine. From there, you can import the disk and set it as the default boot disk. Log in to Proxmox and create a new Virtual Machine.

creating a new vm.

2. Create the VM without any media and in the Disks section, delete the default disk. The goal is to create a completely blank VM (so you don’t have to delete disks later).

removing the disk.

3. Continue with the creation of the VM and note down the VM ID. We will need that for a later step, but as soon as it’s created. access the Shell of the Proxmox host.

accessing the shell of the hypervisor.

4. This step will be different for everyone. You must find the actual QCOW2 image from your Proxmox host. This will allow you to import the image into the blank VM that we created in a prior step. My QCOW2 image is stored on my Synology NAS, so I navigated to the path where the image exists.

finding the qcow2 image file.

5. With the VM ID for the blank virtual machine, run the command below to import the QCOW2 image to the disk. Keep in mind that you must use the correct information as shown below:

  • VM_ID: Virtual Machine ID (in my example, 117).
  • IMAGE_NAME: The name of the QCOW2 file (in my case, wundertech.qcow2).
  • VM_STORAGE: If you’d like to use a specific disk, you can specify it here.
qm importdisk [VM_ID] [IMAGE_NAME] [VM_STORAGE]
accessing the proxmox shell

6. Wait for the transfer to complete (it’ll take a little while depending on the size of the QCOW2 file), then open the virtual machines settings (where you just added the disk).

How to Import QCOW2 Images in Proxmox

Adding the Imported Disk to the Virtual Machine

Now that the virtual machine has the disk imported, we can import it into the blank virtual machine that we created earlier.

1. Open the settings for it and select Hardware. From there, you should see your new disk (it will be unused). Double-click the new disk (or edit it) so that we can add it to the VM.

adding the unused disk.

2. Select Add to add the disk to the virtual machine.

adding the disk.

3. After the disk has been edited, select Options, edit the Boot Order, then select the disk we added and move it to the top. After modifying this, the virtual machine will use this VM as the boot disk.

changing the boot order.

4. You can now start the VM! If the disk you imported had a valid operating system on it, you should be able to log in the way you did on the last hypervisor inside of the Console window.

Conclusion & Final Thoughts

If you’re ever in a position where you’re switching to Proxmox, you may want to import QCOW2 images directly into Proxmox which will be the fastest and least intrusive way to migrate a VM. While this isn’t something everyone will do and isn’t an export option from various hypervisors, if you can export an image in QCOW2, this is one of the easiest ways to import a VM.

Thanks for checking out the article on how to import QCOW2 images in Proxmox. If you have any questions, feel free to leave them in the comments!