Skip to navigationSkip to content
libvirtd docs
Commands

Manual nav

Search `/` or jump with `g` / `G`.

Portal

  • Home manual
  • Command explorer
Foundations6 sections
  • Overview1
  • Installation2
  • Platform1
  • Concepts5
  • Domains2
  • Domain XML2
Subsystems9 sections
  • Identity1
  • Automation2
  • Daemons3
  • virsh3
  • Networking5
  • Storage4
  • Security3
  • Observability2
  • Remote Access1
Operations6 sections
  • Migration2
  • Backup2
  • Performance3
  • Recovery1
  • Troubleshooting2
  • References2

/ search · g top · G quickstart

manxmlReviewed July 15, 2026

CPU, memory, and device model

The domain XML describes a virtual machine contract: machine type, firmware, CPU compatibility, memory, and each presented device. Inspect the effective model CPU choices host passthrough exposes host CPU features closel

domain-xmlcpumemoryvirtio

The domain XML describes a virtual machine contract: machine type, firmware, CPU compatibility, memory, and each presented device.

Inspect the effective model

BASH
virsh dumpxml guest01 --inactive
virsh domcapabilities --virttype kvm --arch x86_64
virsh hypervisor-cpu-baseline /root/cpu-models.xml

CPU choices

host-passthrough exposes host CPU features closely and usually maximizes performance. A named baseline model improves migration compatibility across unlike hosts. Choose based on the fleet, not one server.

Device defaults

  • Prefer virtio for disks and network interfaces when the guest has drivers.
  • Use q35 for modern PCIe-oriented machine definitions unless compatibility requires an older model.
  • Treat firmware variables, TPM state, and NVRAM as data that must move with the guest.
  • Pin emulator and vCPU threads only after measuring contention and NUMA placement.

Validate against host capabilities

An XML document can be syntactically valid but impossible on the target host. Compare machine types, CPU models, firmware paths, device support, and storage accessibility before define or migration.

Related

  • Safe domain XML editing
  • CPU topology, NUMA, and huge pages
  • Virtio and guest disk I/O

On this page

  • Inspect the effective model
  • CPU choices
  • Device defaults
  • Validate against host capabilities