
The incus-migrate tool imports an existing machine (a virtual machine from another hypervisor, a disk, or even a physical server) into Incus, as an instance. It works interactively: you tell it the target Incus server, the source to import and a few options, and it does the rest. This guide walks the procedure, the accepted formats and the UEFI and NVRAM trap that so often stops an imported machine from booting. For people migrating from VMware, Proxmox or a physical server.
What you will learn
- Fetch and run
incus-migrate. - The interactive flow of the import.
- The accepted disk formats.
- The UEFI trap that prevents boot, and how to work around it.
Prerequisites
- A target Incus server with its API exposed on the network (
core.https_address). rsyncinstalled on the source machine.- An access token for the Incus server (
incus config trust add) or a certificate.
Fetching the tool
On a system installed from the Zabbly repositories, incus-migrate ships in the incus-extra package:
sudo apt install incus-extrawhich incus-migrate # /usr/bin/incus-migrateFailing that, it is also a standalone binary published in the assets of the Incus releases, which is handy on a source machine that does not carry the repository:
wget https://github.com/lxc/incus/releases/download/<version>/bin.linux.incus-migrate.x86_64chmod u+x bin.linux.incus-migrate.x86_64sudo ./bin.linux.incus-migrate.x86_64The interactive flow
The tool asks a series of questions; there is no long command line to memorise.
-
Local or remote target: "The local Incus server is the target". Answer no to import into a remote Incus server, then give its URL and validate the certificate fingerprint.
-
Authentication: three choices, including the token generated with
incus config trust add. The tool then prints the name and version of the remote server. -
Type: container, virtual machine, a VM from an
.ova, or a custom volume. -
Target within the cluster: if the target is a cluster, an extra question asks whether to aim at a specific node, otherwise placement is automatic.
-
Name and source: the instance name, then the path to the rootfs (container) or to the disk or bootable image (VM), plus any additional mounts.
-
UEFI Secure Boot (VM only): the question "Does the VM support UEFI Secure Boot?" sets
security.securebooton the created instance. -
Overrides (optional): profiles, storage pool, size, network, disks, before launching with "Begin the migration".
Here is the real end of a container import into an Incus 7.0 cluster (source: the / of a machine, target: the cluster):
Remote server: Hostname: node1 Version: 7.0.0
Instance to be created: Name: imported-box Project: default Type: container Source: /
Additional overrides can be applied at this stage:1) Begin the migration with the above configuration...Please pick one of the options above [default=1]:Transferring instance: imported-box: 1.08GB (35.90MB/s)Instance imported-box successfully createdThe transfer runs over rsync, hence the prerequisite. The instance is then created, stopped, ready to start. On a cluster it is placed automatically (here on node3) unless you targeted a node:
+--------------+---------+-----------+----------+| NAME | STATE | TYPE | LOCATION |+--------------+---------+-----------+----------+| imported-box | STOPPED | CONTAINER | node3 |+--------------+---------+-----------+----------+The accepted formats
For a virtual machine, incus-migrate consumes the common formats directly: raw, qcow2, ova and vmdk. The qcow2 and vmdk support arrived together in Incus 6.6, so no manual conversion is needed for any of them.
For an image coming from VMware or VirtualBox, preprocessing with virt-v2v is often necessary to inject the virtio drivers, without which the disk is not detected at boot:
virt-v2v -i disk source.vmdk -o local -of raw --block-driver virtio-scsiThe UEFI and NVRAM trap
This is the classic headache: the imported machine does not boot, showing a black screen or a UEFI shell.
One more thing to watch: without the virtio drivers in the image (VMware or VirtualBox), the disk is not seen at boot, which is what virt-v2v is for.
Key points
incus-migrateimports a virtual or physical machine into Incus, interactively; it ships in theincus-extrapackage, or as a standalone binary.- Answer no to "local server is the target" to aim at a remote server; on a cluster, placement is automatic unless a node is targeted.
- Prerequisites: the API exposed (
core.https_address),rsyncon the source, and an access token (incus config trust add). - Direct formats: raw, qcow2, ova and vmdk (qcow2 and vmdk since Incus 6.6).
- UEFI trap: the boot configuration lives in NVRAM, not on the disk, so prepare a fallback with
grub-install --removable. - VMware and VirtualBox images: inject the virtio drivers with
virt-v2v.
FAQ: common questions about incus-migrate
The incus-migrate tool
chmod u+x bin.linux.incus-migrate.x86_64
sudo ./bin.linux.incus-migrate.x86_64
This standalone binary, published in the Incus releases, works interactively: it asks for the target server, the authentication (token), the type, the source disk, UEFI support, then any overrides.
Prerequisites: the Incus API exposed (core.https_address) and rsync on the source machine.
raw, qcow2, ova and vmdk
incus-migrate accepts raw, qcow2, ova and vmdk directly, with no manual conversion. The qcow2 and vmdk support arrived together in Incus 6.6.
For a VMware or VirtualBox image, preprocessing with virt-v2v is often required to inject the virtio drivers:
virt-v2v -i disk source.vmdk -o local -of raw --block-driver virtio-scsi
Without those drivers, the disk is not detected at boot.
The UEFI and NVRAM trap
The UEFI boot configuration lives in the NVRAM of the original machine, not in the disk image. Converting the disk therefore does not restore the boot entry, the classic VirtualBox to Incus case.
The workaround, applied before the migration, creates a standard fallback boot path:
grub-install /dev/sdX --removable
That writes \EFI\BOOT\bootx64.efi, which firmware always looks for.
virt-v2v, then incus-migrate
VMware and VirtualBox images often lack the virtio drivers Incus expects. Prepare the image:
virt-v2v -i disk source.vmdk -o local -of raw --block-driver virtio-scsi
Then import with incus-migrate. Also anticipate the UEFI trap (boot configuration in NVRAM) with grub-install --removable on the source before migrating.
Next steps
- Debugging an Incus VM stuck at boot: the exact procedure for an imported machine stuck in emergency mode.
- Migration Manager: the batch tool when a whole VMware estate has to move.
- Automating Incus image builds: build your own images rather than importing legacy machines indefinitely.