Use this when deciding how VMs share host capacity, or when a VM is slow despite free host resources because of limits, shares or reservations.
Resource Management
Resource management controls how VMs share host capacity: reservations guarantee a minimum, limits cap the maximum, shares set priority under contention, and resource pools group VMs so these rules apply together.
1. Resource controls: shares (priority), reservations (guarantee), limits (cap).
2. Use shares first; limits rarely.
3. Reservations reduce admission capacity.
4. Apply to pools, not single VMs, where possible.
5. Measure contention before tuning.
demand → shares/reservations/limits → scheduler/allocator
Context & applicabilityCommon mistakes · platform/version boundaries
- Using limits instead of shares to prioritise.
- Reservations on many VMs, blocking HA restart.
- Resource pools used as folders.
- Settings copied from templates without review.
Operational reference
Fast context before you go deeper.
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.
Subtopics
Go one level deeper into this subject.
Resource pools group VMs and assign them shares, reservations and limits as a unit, for example per department or environment.
Subtopic CPU LimitsA CPU limit caps how much CPU (in MHz or percent) a VM may use even when the host is idle.
Subtopic CPU ReservationsA CPU reservation guarantees a VM a minimum amount of CPU capacity.
Subtopic CPU SharesCPU shares set a VM's relative priority only when the host is contended: a VM with twice the shares gets about twice the CPU.
Subtopic Memory LimitsA memory limit caps the physical RAM a VM can use below its configured size; anything above the limit is ballooned or swapped even if the host has free memory.
Subtopic Memory ReservationsA memory reservation guarantees that part or all of a VM's memory is always backed by physical RAM and never swapped.
Subtopic Memory SharesMemory shares decide which VMs keep their memory when the host runs short: under pressure, VMs with fewer shares are ballooned or swapped first.
Subtopic Disk LimitsDisk limits cap a VM's IOPS or throughput (for example vSphere IOPS limits, Hyper-V Storage QoS, libvirt iotune) so one busy VM cannot starve others on the same datastore.
Subtopic Network LimitsNetwork limits cap or shape a VM's or port group's bandwidth (traffic shaping, Network I/O Control, Hyper-V bandwidth management, tc on Linux) so one VM or traffic type cannot saturate a shared uplink.
Subtopic QoSVirtualization QoS combines shares, reservations and limits for CPU, memory, storage and network so important workloads keep performance when resources are contended, and noisy neighbours are contained.
Subtopic Resource ContentionResource contention happens when VMs demand more CPU, memory, storage or network than the host can deliver.
- Limits apply even when the host is idle.
- Shares only matter under contention.
- Reservations reduce what others and HA can use.
virsh schedinfo <vm>— CPU shares/quota (libvirt)Get-VMProcessor <vm> | fl Reserve,Maximum,RelativeWeight— Hyper-V CPU controlsqm config <vmid> | grep -E 'cpulimit|cpuunits|memory'— Proxmox controls
ReferenceWhy it matters1 section · depth on demand
Controls summary
| Control | CPU | Memory | Storage | Network |
|---|---|---|---|---|
| Reservation (guarantee) | MHz | MB | IOPS (some) | Mbit/s (NIOC) |
| Limit (cap) | MHz | MB | IOPS, MB/s | Traffic shaping |
| Shares (priority under contention) | Yes | Yes | SIOC | NIOC |
Prefer shares and right-sizing; use reservations for critical VMs and limits only deliberately.
ReferenceHow it works1 section · depth on demand
In depth
Resource controls decide who gets CPU, memory, disk and network when there is contention:
| Control | Effect | When it matters |
|---|---|---|
| Reservation | Guaranteed minimum | Always (blocks other VMs from using it) |
| Limit | Hard maximum | Always (even if resources are idle) |
| Shares/weight | Relative priority | Only under contention |
Prefer shares for prioritisation, reservations for critical VMs that must always get their minimum, and limits only for metering, tenants or noisy neighbours — limits silently throttle VMs even when the host is idle.
ReferenceImportant terms & boundaries1 section · depth on demand
Order of effect
1. Reservations guarantee resources and are honoured first.
2. Limits cap resources even when the host is idle.
3. Shares split what remains when there is contention.
Most VMs need none of these. Use reservations for critical VMs, avoid limits, and use shares or resource pools to prioritise groups.
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 Resource Management. Documentation verification only; this is not observed lab or production Evidence.
Basis: https://libvirt.org/html/libvirt-libvirt-domain.html · confidence 94%