Use this topic when the symptom or planned change has been narrowed to KVM / QEMU → libvirt. Establish effective host/runtime state before changing configuration.
libvirt
Treat libvirt as desired/persistent domain configuration plus runtime orchestration over a hypervisor driver; persistent XML, live runtime state and the underlying QEMU process can differ.
1. libvirt manages VMs (domains), networks, storage pools and node devices.
2. qemu:///system for system VMs.
3. Remote: qemu+ssh://host/system.
4. XML definitions in /etc/libvirt/qemu/.
5. Edit with virsh edit, not files.
client → libvirt → QEMU/KVM
Context & applicabilityCommon mistakes · platform/version boundaries
It does not show root cause from one status line, process state or log message, and it does not show unobserved guest/application or external dependency health. libvirt can show what it requested or observes through the driver; it does not automatically show guest-internal or external dependency health.
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 Verification path Verify boundary
Management client → libvirt API/URI → QEMU driver → domain XML/live state → QEMU process → guest/backends → workload
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.
- libvirt ≠ hypervisor.
- Persistent domain XML ≠ live domain configuration after runtime-only changes.
- Domain Active ≠ guest/application healthy.
- A libvirt API success may prove management action completion without proving the resulting workload outcome.
virsh uri— connection URIvirsh list --all— domainsvirsh net-list --all; virsh pool-list --all— networks and pools
ReferenceWhy it matters1 section · depth on demand
In depth
libvirt is the management layer for KVM/QEMU (and other hypervisors): domain XML definitions, storage pools, networks, a stable API and the virsh CLI. Tools built on it include virt-manager, Cockpit, OpenStack Nova and KubeVirt.
virsh -c qemu:///system list --all
virsh dumpxml vm1 > vm1.xml
virsh edit vm1 # validated edit
virsh define vm1.xml; virsh undefine vm1 --nvram
virsh -c qemu+ssh://root@kvm02/system list
qemu:///system manages system-wide VMs; qemu:///session runs per-user VMs with fewer privileges.
ReferenceImportant terms & boundaries2 sections · depth on demand
What this shows and what it does not
libvirt can show what it requested or observes through the driver; it does not automatically show guest-internal or external dependency health.
Reference
virsh list --all
virsh dumpxml vm01 | less
virsh edit vm01
virsh net-list --all ; virsh pool-list --all
Documented example, not captured output.
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 KVM / QEMU → libvirt. Documentation verification only; this is not observed lab or production Evidence.
Basis: https://www.qemu.org/docs/master/ · confidence 94%Terms & aliases
Hover a linked term for a quick definition; click it to open its glossary entry. Aliases are other names that find this Topic in search.
Quick lookup tables
KVM / QEMU → libvirt reference map
Fast operational boundaries and evidence limits for KVM / QEMU → libvirt.
| Boundary | What to verify | Evidence limit |
|---|---|---|
| Definition/config | Expected KVM / QEMU → libvirt definition or configuration is present | Configured state does not prove runtime behavior |
| Runtime | Relevant KVM/QEMU/libvirt object or process is active without matching errors | Runtime state does not prove dependencies or guest outcome |
| Dependency | Host CPU/memory, storage, network or device backend required by this path is healthy | Local success does not prove the next boundary |
| Acceptance | Original guest/application test succeeds after the change or observation | Required for end-to-end closure |