EXAMPLES
Common libvirtd and virsh examples
Small, copy-ready examples for daemon checks and virtualization inventory.
Reference core
verify upstream ↗$ libvirtd --versionPrint the installed libvirtd/libvirt version.
$ libvirtd -dStart the monolithic daemon in traditional background mode.
$ virsh --connect qemu:///system list --allList all QEMU/KVM domains visible through the system libvirt instance.
$ virsh uriPrint the canonical URI for the current virsh connection.
$ systemctl status libvirtd.socket libvirtd.serviceInspect the monolithic socket and service when the host uses libvirtd.
$ systemctl status virtqemud.socket virtqemud.serviceInspect the modular QEMU daemon when the host uses modular libvirt.
$ virsh net-list --allList defined libvirt virtual networks.
$ virsh pool-list --allList defined libvirt storage pools.
$ virsh dumpxml DOMAINDisplay a domain XML definition.
Living manual · why this matters
How do you turn examples into a safe workflow?
Start by proving the connection URI, inventorying state and reading definitions before mutating anything. The examples below are deliberately small building blocks; the living manual links them to deeper domain, network, storage and daemon procedures.
Operator checks
$ virsh uri$ virsh list --all$ virsh dominfo DOMAIN$ virsh net-list --all$ virsh pool-list --all$ virsh dumpxml DOMAINWhat to notice
- Read before change: URI, current state and XML first.
- Use --all when inactive definitions matter.
- After any state change, verify both the immediate result and persistent/autostart expectations.
Deep reference