Loading...

We've detected that your browser language is Chinese. Would you like to visit our Chinese website? [ Dismiss ]
By: Emma

Moving a virtual appliance from VMware or VirtualBox to a KVM-based platform means dealing with one immediate problem: format incompatibility. Your exported OVA file won’t work directly on Proxmox, a KVM host, or an EVE-NG lab — each of these expects a QCOW2 image instead.

This guide walks through the full conversion process on Linux, Windows, and Proxmox, with step-by-step commands and solutions to common issues.

What Are OVA and QCOW2? (And Why Convert?)

Before running any commands, it helps to understand what you are actually working with.

An OVA (Open Virtualization Archive) is not a single disk file. It is a compressed TAR archive that bundles three components together:

  • .vmdk — the virtual disk
  • .ovf — the configuration file (XML format)
  • .mf — the manifest file (not needed for conversion)

QCOW2 (QEMU Copy On Write v2) is the standard disk format for KVM-based hypervisors. Unlike VMDK, it supports thin provisioning, built-in snapshots, and AES encryption natively.

how to convert ova to qcow2

OVA vs. QCOW2 at a Glance

Feature OVA (VMDK) QCOW2
Primary Platforms VMware, VirtualBox KVM, QEMU, Proxmox, EVE-NG
File Type Archive (TAR) Single disk image
Snapshots Hypervisor-managed Built-in native support
Disk Allocation Fixed or dynamic Thin provisioning
Compression Manual (zlib) Native support

Why Convert?

The main reason to convert OVA to QCOW2 is cross-hypervisor migration. If you are setting up a Proxmox homelab, deploying a network appliance in EVE-NG, or moving a legacy VMware workload to a KVM-based environment, the disk format should match what the target platform expects before the VM can boot.

How to Convert OVA to QCOW2 on Linux

The Linux command line is the most straightforward environment for this conversion. The qemu-img utility handles virtual disk format changes and is available on most major distributions.

Prerequisites

Before starting, make sure you have the following:

  • A valid .ova file: An export from VMware, VirtualBox, or a downloaded vendor appliance.
  • qemu-utils installed: On Ubuntu/Debian, run sudo apt install qemu-utils. On RHEL/CentOS, use sudo yum install qemu-img.
  • Sufficient disk space: A 20 GB OVA can expand to 40 GB or more during conversion, depending on the virtual disk size.
  • Root or sudo access: Required for moving files to system directories later.

Step 1: Extract the OVA File

An OVA is a TAR archive, so you need to unpack it before converting anything.

bash
tar -xvf your-appliance.ova

This produces several files. The one you need is the .vmdk file — the virtual hard disk. The .ovf (configuration) and .mf (manifest) files are also extracted, but you can ignore them for this conversion.

Step 2: Convert VMDK to QCOW2 with qemu-img

With the VMDK extracted, run the following command to convert it:

bash
qemu-img convert -p -f vmdk -O qcow2 your-disk-image.vmdk output-image.qcow2

What each flag does:

  • -p — Shows a progress bar. Useful for large disks.
  • -f vmdk — Declares the source format as VMDK.
  • -O qcow2 — Sets the output format to QCOW2.
Note: The -p flag needs come before -f and -O to work correctly with some versions of qemu-img. Placing it at the end may cause it to be ignored.

Step 3: Verify the Converted Image

After conversion, confirm the output file is valid:

bash
qemu-img info output-image.qcow2

Check that the file format line reads qcow2. The output also shows the virtual disk size versus the actual space consumed on disk — useful for spotting any unexpected size differences.

Step 4: Optional: Shrink the QCOW2 File

The converted file may be much larger than the data it actually holds, because empty blocks are preserved during conversion. You can compact it with a second pass:

bash
qemu-img convert -O qcow2 output-image.qcow2 output-shrunk.qcow2

This rewrites the file and skips empty blocks. A 100 GB virtual disk with only 5 GB of actual data can shrink dramatically. The original file is not modified, so you can delete it once you have verified the shrunk version.

Step 5: Use the QCOW2 with KVM / virt-manager

To attach the disk to a VM in a KVM environment:

1. Move the file to the default image directory:

bash
sudo mv output-image.qcow2 /var/lib/libvirt/images/

2. Open virt-manager (Virtual Machine Manager).

3. Click New Virtual Machine.

4. Select Import existing disk image.

5. Browse to your QCOW2 file and complete the setup by configuring CPU and RAM.

How to Convert OVA to QCOW2 in Windows

Windows does not support OVA or QCOW2 natively, but you have two options without switching to a Linux machine: using the Windows Subsystem for Linux (WSL) or a native Windows build of qemu-img.

Prerequisites

Before starting, make sure you have:

  • A valid .ova file: An export from VMware, VirtualBox, or a downloaded vendor appliance.
  • Sufficient disk space: The converted QCOW2 file can be as large as the virtual disk size declared in the OVA, so leave extra room.
  • 7-Zip installed: Required for Method 2 to extract the OVA archive. Download it from 7-zip.org if you don’t have it.
  • Administrator access: Needed for installing WSL or running conversion commands on system drives.

Method 1: Using WSL (Recommended)

WSL lets you run Linux tools directly on Windows, which makes this the most reliable method. The commands are identical to the Linux workflow.

1. Install WSL: Open PowerShell as Administrator and run:

powershell
wsl --install

This installs WSL 2 with Ubuntu by default. Restart your machine when prompted. If Ubuntu is already installed, skip to step 2.

2. Install qemu-utils: Inside your WSL Ubuntu terminal, run:

bash
sudo apt update && sudo apt install qemu-utils -y

3. Access your files: Windows drives are mounted inside WSL under /mnt/. To navigate to your Downloads folder on the C: drive:

bash
cd /mnt/c/Users/YourName/Downloads/

4. Extract and convert: Follow the same tar and qemu-img steps from the Linux section above.

Method 2: Using qemu-img Windows Native Binary

If you prefer not to use WSL, you can use a standalone Windows build of qemu-img.

  1. Download the tool: Get the qemu-img for Windows binary from the QEMU official site or the Cloudbase Solutions build. Extract the archive to a folder such as C:\qemu\.
  2. Extract the OVA: Right-click your .ova file in 7-Zip and select Extract here. This unpacks the .vmdk, .ovf, and .mf files.
  3. Run the conversion: Open PowerShell or Command Prompt in the folder containing your VMDK and run:
powershell
   .\qemu-img.exe convert -p -f vmdk -O qcow2 "source-disk.vmdk" "output-disk.qcow2"
Note: Wrapping file paths in double quotes prevents errors if the filename contains spaces.

Limitations of Method 2: The Windows binary of qemu-img may lag behind the Linux version in terms of updates and performance. For production use or large disks, WSL is the more dependable option.

Common Issues on Windows

  • File path spaces: If your path contains spaces (e.g., C:\Virtual Machines\), the command will fail unless you wrap the path in double quotes, as shown above.
  • Long path errors: Windows has a maximum path length limit. If a conversion fails unexpectedly, move the .vmdk to a short path such as C:\temp\ and try again.
  • Permission denied: Open PowerShell as Administrator if you are working with files on a system drive.
  • Slow conversion speed: NTFS file handling makes disk writes slower than on Linux. A 50 GB disk can take several minutes. This is expected behavior.

 How to Convert OVA to QCOW2 for Proxmox

Proxmox VE is one of the most common destinations for OVA migrations. The web interface does not have a direct OVA import option, but Proxmox provides command-line tools that handle the process reliably.

Method 1: Convert on the Proxmox Host Directly

This approach avoids uploading a large converted disk from your local machine. Instead, you transfer the smaller OVA first, then extract and convert directly on the host.

1. Upload the OVA: Use an SCP client such as WinSCP or the scp command to transfer the OVA to your Proxmox host. A safe destination is /tmp/.

2. SSH into Proxmox: Connect as root:

bash
ssh root@<your-proxmox-ip>

3. Extract and convert:

bash
tar -xvf your-appliance.ova
qemu-img convert -p -f vmdk your-disk.vmdk -O qcow2 managed-disk.qcow2

4. Import the disk to a VM: Replace 100 with your actual VM ID and local-lvm with your target storage name:

bash
qm importdisk 100 managed-disk.qcow2 local-lvm
Note: The VM must already exist in Proxmox before running this command. If you have not created it yet, do so first via the web UI with no disk attached.

Method 2: Direct OVA Conversion

Some versions of qemu-img can read through the OVA’s TAR wrapper and convert directly, without manually extracting the VMDK first:

bash
qemu-img convert -p your-appliance.ova -O qcow2 output.qcow2

This only works reliably when the OVA contains a single virtual disk. If the appliance has multiple disks, this method may fail or convert only the first disk. When in doubt, use Method 1.

Method 3: Using qm importovf (Native Proxmox Import)

Proxmox includes a built-in command that reads the .ovf configuration file and creates the VM automatically, including CPU and RAM settings.

1. Extract the OVA:

bash
tar -xvf appliance.ova

2. Run the import: Replace 100 with your VM ID and local-lvm with your storage name:

bash
qm importovf 100 ./appliance.ovf local-lvm --format qcow2

Common error: If you see “invalid host resource,” the OVF is referencing a network name (such as “VM Network”) that does not exist on your Proxmox host. You can safely ignore this and configure the network interface manually in the web UI afterward.

When to use this method: qm importovf is best when you want Proxmox to configure the VM settings automatically from the OVF file. Use Method 1 if you prefer to control the VM configuration yourself.

Post-Import Checklist for Proxmox

After importing the disk, the VM will not boot until you complete these steps in the Proxmox web UI:

  • Attach the disk: Go to the VM’s Hardware tab. Find the Unused Disk entry, double-click it, and click Add.
  • Set the boot order: Go to Options > Boot Order. Check the imported disk and move it to the top of the list.
  • Check the BIOS type: VMware VMs often use UEFI, while Proxmox defaults to SeaBIOS. If the VM fails to find a bootable disk, go to Hardware > BIOS and switch from Default (SeaBIOS) to OVMF (UEFI).
  • Reconfigure the network: The network interface name will likely change after migration. Log in via the Proxmox console and update your network configuration — for example, editing /etc/netplan/*.yaml on Ubuntu or /etc/sysconfig/network-scripts/ on RHEL-based systems.

Bonus: How to Convert OVA to QCOW2 for EVE-NG

Network engineers often need a QCOW2 image to run virtual firewalls and routers — such as Palo Alto, FortiGate, or Cisco appliances — inside EVE-NG (Emulated Virtual Environment Next Generation).

The conversion steps are the same as the Linux method, but EVE-NG has strict requirements for folder names and disk file names. Follow these exactly, or the node will not appear or boot correctly.

1. Create the device directory: EVE-NG expects each node type to live in its own named folder under /opt/unetlab/addons/qemu/. The folder name should match the image name you configure in EVE-NG. For example, for Palo Alto PAN-OS 9.0.1:

bash
mkdir -p /opt/unetlab/addons/qemu/paloalto-9.0.1/

2. Upload and extract the OVA: Transfer your OVA to the device directory via SCP, then extract it:

bash
tar -xvf your-appliance.ova

3. Convert and rename the disk: EVE-NG requires the disk file to be named virtioa.qcow2 or hda.qcow2 depending on the node type. Convert and name it in one step:

bash
qemu-img convert -p -f vmdk appliance-disk1.vmdk -O qcow2 virtioa.qcow2
Note: Check the EVE-NG community documentation for the correct disk name for your specific appliance. Using the wrong name will cause the node to fail on startup.

4. Fix permissions: Run this after every image addition. It sets the correct ownership and permissions so the EVE-NG hypervisor can read the file:

bash
/opt/unetlab/wrappers/unl_wrapper -a fixpermissions

Cross-Hypervisor V2V Migration: Beyond Manual Conversion

The command-line methods covered in this guide work well for one-off conversions. But if you are managing a larger migration — moving dozens of VMs from a VMware environment to KVM or Proxmox, or transitioning workloads across data centers — manual extraction and conversion quickly becomes time-consuming and error-prone.

Format incompatibility is only part of the challenge. Keeping production systems running during the transition, validating data integrity after the move, and handling legacy operating systems all add complexity that qemu-img alone cannot address.

i2Migration is a unified migration platform built for exactly these scenarios. It supports live, non-disruptive migration across physical, virtual, and cloud environments — without requiring manual disk extraction or format conversion steps.

Key Features of i2Migration

  • Zero-downtime migration: i2Migration uses a combination of block-level and file-level replication to migrate running systems without shutting down production workloads. Your VMs stay online throughout the process.
  • Cross-platform coverage: Supports P2V, V2V, V2P, physical-to-cloud, and virtual-to-cloud migrations. Whether you are moving from VMware to KVM, consolidating data centers, or shifting workloads to a public cloud, the platform handles the environment difference.
  • Legacy OS support: One practical limitation of manual QCOW2 conversion is that older operating systems often fail to boot after migration due to driver mismatches. i2Migration handles driver injection and BIOS/UEFI conversion automatically, which improves boot success rates on heterogeneous hardware.
  • Built-in validation: After migration, i2Migration performs end-to-end dataset verification. This removes the guesswork of checking whether a manually converted disk is actually intact.
  • Secure transfer: Data is transmitted with AES/SM4 encryption, with bandwidth control and resume-from-breakpoint support — useful when migrating large disks across slow or unstable network links.

For teams that need to migrate at scale or cannot afford downtime during the transition, i2Migration offers a more controlled and auditable path than manual conversion.

If you are rethinking your virtualization infrastructure, data protection is the other side of the equation. Once your VMs are running on the new platform, i2Backup provides centralized backup across physical servers, virtual machines, and databases — including Proxmox and KVM environments. For workloads where availability is critical, i2Availability adds real-time replication and automatic failover to keep services running if a host goes down.

Click the button to get a free trial of Info2soft’s solutions!

FREE Trial for 60-Day

FAQ

Q1: Can I convert OVA to QCOW2 directly without extracting?

Sometimes. If the OVA contains a single disk and you are running a recent version of qemu-img, direct conversion can work. That said, extracting the TAR file first is the safer approach — it lets you confirm which VMDK file to use, especially when the appliance includes multiple disks.

 

Q2: Is QCOW2 better than VMDK?

It depends on the platform. VMDK is the standard format for VMware environments. QCOW2 is optimized for KVM-based hypervisors like Proxmox and offers native compression, built-in snapshot support, and copy-on-write behavior that uses disk space more efficiently. If you are running KVM or Proxmox, QCOW2 is the better choice.

 

Q3: How do I convert a CentOS QCOW2 image back to OVA?

There is no single command for this. The process involves two steps: first, convert the QCOW2 to VMDK using qemu-img, then import that VMDK into VirtualBox or VMware and export it as an OVA.

The conversion command is:

bash
qemu-img convert -p -f qcow2 -O vmdk input.qcow2 output.vmdk

 

Q4: How long does conversion take?

It depends on disk speed and virtual disk size. A 40 GB VMDK typically converts in 2 to 5 minutes on an NVMe drive. On a traditional HDD, expect significantly longer. The -p flag in qemu-img shows a progress bar so you are not left guessing.

 

Q5: Can I convert back from QCOW2 to OVA?

Yes. Convert the QCOW2 back to VMDK using qemu-img, then use VMware Workstation or VirtualBox to wrap the VMDK into an OVF/OVA archive. The steps are essentially the reverse of what this guide covers.

Conclusion

Converting OVA to QCOW2 comes down to a few consistent steps: extract the archive, convert the VMDK with qemu-img, verify the output, and attach the disk to your target VM. The platform you are working on — Linux, Windows, or Proxmox — changes the tooling slightly, but the core process stays the same.

A few things worth keeping in mind before you wrap up:

  • Always run qemu-img info after conversion to confirm the output file is valid.
  • If the converted disk is larger than expected, use a second qemu-img pass to compact it.
  • On Proxmox, do not skip the post-import checklist — boot order and BIOS type are the two most common reasons a migrated VM fails to start.
  • For EVE-NG, double-check the folder name and disk file name against the official community documentation before running fixpermissions.

For one-off migrations, the manual methods in this guide are practical and free. If you are moving multiple VMs or need to keep production systems online during the transition, a dedicated migration platform like Info2soft’s i2Migration removes much of the manual work and adds built-in validation to the process.

Emma is the bridge between complex engineering and the people who need it. As a content creator at Info2Soft, she spends her days translating "tech-speak" into clear, actionable stories about data resilience. She’s not just documenting software; she's uncovering how data replication and recovery actually change the way businesses run.

More Related Articles

Table of Contents:
Stay Updated on Latest Tips
Subscribe to our newsletter for the latest insights, news, exclusive content. You can unsubscribe at any time.
Subscribe
Ready to Enhance Business Data Security?
Start a 60-day free trial or view demo to see how Info2soft protects enterprise data.
{{ country.name }}
Please fill out the form and submit it, our customer service representative will contact you soon.
By submitting this form, I confirm that I have read and agree to the Privacy Notice.
{{ isSubmitting ? 'Submitting...' : 'Submit' }}