Storage pools and backends
Libvirt pools abstract where guest disks live. The pool type tells you which backend owns the bytes and which operational failure modes to expect. Common pool types | Type | What it maps to | Operational note | | | | | |
Libvirt pools abstract where guest disks live. The pool type tells you which backend owns the bytes and which operational failure modes to expect.
Common pool types
| Type | What it maps to | Operational note |
|---|---|---|
dir | A filesystem directory | Simplest to inspect and back up |
logical | LVM volume group | Fast and common for dense local hosts |
netfs | NFS export | Shared storage with external network dependency |
iscsi | iSCSI target | Block storage with network path and initiator state |
Pool lifecycle
virsh pool-list --all
virsh pool-info fast-lvm
virsh pool-dumpxml fast-lvm
virsh vol-list fast-lvmSystem-scope inventory
When the task is to inventory host-wide pools, make the libvirt connection scope explicit instead of relying on a shell default:
virsh --connect qemu:///system pool-list --all--connect qemu:///system selects the host-wide QEMU/libvirt instance, pool-list requests storage pools, and --all includes inactive pools as well as active ones.
What to read first
- For
dir, inspect the directory path, ownership, and mount state. - For LVM, inspect the volume group and free extents.
- For NFS, confirm the mount is live before blaming libvirt.
- For iSCSI, verify the session and device visibility on the host.
Read-only inspection boundary
When a block-backed filesystem must be inspected without taking write custody, create a dedicated inspection mountpoint and make the read-only intent explicit.
mkdir -p /mnt/inspect
mount -o ro /dev/mapper/vmdata /mnt/inspect
findmnt -no SOURCE,TARGET,OPTIONS /mnt/inspect
umount /mnt/inspectmount -r and mount --read-only express the same read-only intent. Do not mount a filesystem a second time merely because a device exists; first prove whether it is already mounted, active in a guest, or otherwise owned by another layer.
Safety checks
Never assume a pool that is defined is also started, mounted, or healthy.