QEMU and Firmware Detection
Cubic relies on QEMU and UEFI firmware to create and run virtual machines. When you start a VM, Cubic automatically searches for these tools in standard locations. This page explains where Cubic looks and how to override the detected paths when needed.
QEMU Binary
Cubic searches for the QEMU system emulator on your PATH. The binary name
depends on the architecture of the virtual machine:
Architecture |
Binary |
|---|---|
amd64 |
|
arm64 |
|
Install QEMU if it is not already present:
Platform |
Command |
|---|---|
Debian / Ubuntu |
|
Fedora / RHEL |
|
Arch Linux |
|
openSUSE |
|
macOS (Homebrew) |
|
Windows |
Install from https://www.qemu.org/download/#windows |
Override
Set CUBIC_QEMU to use a QEMU binary that is not on PATH:
$ CUBIC_QEMU=/opt/qemu/bin/qemu-system-x86_64 cubic start my-vm
qemu-img
Cubic searches for qemu-img on your PATH. This tool is used to create
and resize virtual machine disk images. It is included with QEMU on all
platforms.
Install qemu-img if it is not already present:
Platform |
Command |
|---|---|
Debian / Ubuntu |
|
Fedora / RHEL |
|
Arch Linux |
|
openSUSE |
|
macOS (Homebrew) |
|
Windows |
Install from https://www.qemu.org/download/#windows |
Override
Set CUBIC_QEMU_IMG to use a qemu-img binary that is not on PATH:
$ CUBIC_QEMU_IMG=/opt/qemu/bin/qemu-img cubic create my-vm --image ubuntu:noble
UEFI Firmware
Cubic requires a UEFI firmware image (OVMF for amd64, AAVMF for arm64) to boot virtual machines. Cubic searches a list of well-known paths in order and uses the first file that exists.
AMD64 (OVMF)
Path |
Platform |
|---|---|
|
Snap package |
|
QEMU install directory |
|
Debian / Ubuntu |
|
Fedora / RHEL |
|
Fedora (older) |
|
Arch Linux |
|
openSUSE |
|
Homebrew (Apple Silicon) |
|
Homebrew (Intel) |
|
Linux Homebrew (non-root) |
|
Windows |
Install OVMF if it is not already present:
Platform |
Command |
|---|---|
Debian / Ubuntu |
|
Fedora / RHEL |
|
Arch Linux |
|
openSUSE |
|
macOS (Homebrew) |
|
Windows |
Install from https://www.qemu.org/download/#windows |
ARM64 (AAVMF)
Path |
Platform |
|---|---|
|
Snap package |
|
QEMU install directory |
|
Debian / Ubuntu |
|
Fedora / RHEL |
|
Arch Linux |
|
openSUSE |
|
Homebrew (Apple Silicon) |
|
Homebrew (Intel) |
|
Linux Homebrew (non-root) |
|
Windows |
Install AAVMF if it is not already present:
Platform |
Command |
|---|---|
Debian / Ubuntu |
|
Fedora / RHEL |
|
Arch Linux |
|
openSUSE |
|
macOS (Homebrew) |
|
Windows |
Install from https://www.qemu.org/download/#windows |
Override
Set CUBIC_FW to use a firmware file that was not found by autodetection.
This bypasses the entire candidate search:
$ CUBIC_FW=/usr/share/OVMF/OVMF_CODE.fd cubic start my-vm
Environment Variable Reference
Variable |
Tool |
Description |
|---|---|---|
|
QEMU emulator |
Path to the |
|
qemu-img |
Path to the |
|
UEFI firmware |
Path to the OVMF or AAVMF firmware file to use instead of the autodetected path |