Use this when deploying VMs from distribution cloud images instead of installers.
Cloud Image
A cloud image is a small, prebuilt OS disk (qcow2, VMDK or VHD) published by distributions for virtualization and cloud use. It boots without an installer and is configured on first boot by cloud-init.
1. Cloud images are minimal OS images expecting cloud-init.
2. Download from the distro, verify checksum.
3. Resize disk after import.
4. Need a cloud-init datasource (NoCloud, ConfigDrive).
5. Update regularly.
cloud image → import disk → cloud-init → VM
Context & applicabilityCommon mistakes · platform/version boundaries
Operational reference
Fast context before you go deeper.
Verification & Troubleshooting
Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.
Use the operational verification above to establish the expected state.
Capture the concrete output, symptom, packet, log or counter before changing anything.
Step 1 Common mistakes Narrow the fault
- Using cloud images without cloud-init data.
Evidence · 1 on this Topic
Expected observations and documentation recipes are reference material. Record actual output, device identity, scope and time before claiming a verified result.
- Resize the disk after import; images are small.
- Cloud images have no default password; use keys via cloud-init.
qemu-img info <cloud>.qcow2— cloud image formatvirt-customize -a <img> --root-password password:...— customize offlineqm importdisk <vmid> <img> <storage>— import (Proxmox)
ReferenceWhy it matters1 section · depth on demand
Reference
| Distribution | Source |
|---|---|
| Ubuntu | cloud-images.ubuntu.com |
| Debian | cloud.debian.org/images/cloud |
| Rocky/Alma | dl.rockylinux.org / repo.almalinux.org (GenericCloud) |
| Windows | No official cloud image; build with Sysprep |
ReferenceImportant terms & boundaries2 sections · depth on demand
In depth
Cloud images are minimal, pre-installed OS disks (Ubuntu, Debian, RHEL, Rocky, AlmaLinux) with cloud-init, designed to be cloned and customised at first boot rather than installed interactively.
wget https://cloud-images.ubuntu.com/noble/current/noble-server-cloudimg-amd64.img
qm create 9000 --name ubuntu-2404-tpl --memory 2048 --net0 virtio,bridge=vmbr0 --scsihw virtio-scsi-single
qm importdisk 9000 noble-server-cloudimg-amd64.img local-zfs
qm set 9000 --scsi0 local-zfs:vm-9000-disk-0 --ide2 local-zfs:cloudinit --boot order=scsi0 --serial0 socket --vga serial0 --agent 1
qm template 9000
Verify image checksums/signatures and refresh templates regularly so new VMs do not start months behind on patches.
Using cloud images
wget https://cloud.debian.org/images/cloud/bookworm/latest/debian-12-genericcloud-amd64.qcow2
qm importdisk 9000 debian-12-genericcloud-amd64.qcow2 local-lvm
qm set 9000 --scsi0 local-lvm:vm-9000-disk-0 --ide2 local-lvm:cloudinit --boot order=scsi0
Documented example, not captured output. Verify the image checksum from the distribution's SHA256SUMS before use. Cloud images expect cloud-init to set users, keys and network.
Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Verification history & basis
When and against what this Topic was checked. Later text edits do not count as a new check.
Authoritative/upstream documentation reviewed for bounded claims in VM Templates → Cloud Image. Documentation verification only; this is not observed lab or production Evidence.
Basis: https://libvirt.org/docs.html · confidence 94%