Pcornel
Virtualization

VM Templates

Cheat sheet · https://pcornel.dk/topic.php?topic=3554

Back to the Topic

Answer

VM templates are prepared, generalized master images that new VMs are cloned from, so every deployment starts from the same patched OS, agents and settings and is customized at first boot with Sysprep or cloud-init.

Remember

  • A template must be generalized before cloning.
  • Template age = patch debt of every new VM.
  • Linked clones depend on their parent.

First checks

  • qm list | awk '$3=="template"' — templates (Proxmox)
  • virsh list --all — libvirt templates by naming
  • Get-VM | ? Name -like 'tpl-*' — Hyper-V template VMs

Verify in this order

base VM → generalise → template → clone → customise

Where it usually breaks

First mismatch in guest/app quiescence → hypervisor snapshot/template task → metadata/backing chain → storage durability → restore/clone read-back; preserve identity/native error/pre-state before mutation.

Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=3554

Confirmation

Confirm action

Continue?