Red Hat shows how to forecast VM capacity on OpenShift Virtualization
A new engineering guide uses Prometheus rules and Perses dashboards to estimate how many more VMs fit, when headroom runs out, and what memory overcommit could cost.
A cluster can have spare memory on paper and still not have room for the next batch of VMs. In a Red Hat Developer engineering guide, Raffaele Spazzoli shows how to account for the capacity that must stay free when nodes go offline, forecast when the remaining headroom might run out, and estimate the risk of requesting less memory than guests are configured to use. The companion repository supplies Prometheus recording rules, alerts, and Perses dashboards.
Count the capacity you can actually schedule
The guide starts with allocatable CPU and memory rather than the hardware totals. It subtracts capacity for the nodes the cluster must be able to lose during maintenance or an outage, then subtracts existing workload requests. The dashboard estimates how many more VMs of a specified CPU and memory size fit in that budget and shows which resource runs out first. It also separates VM requests from non-VM requests, such as those from operators and DaemonSets. The cluster-wide estimate is a planning input, not a placement guarantee for any individual VM.
A second view estimates time to exhaustion from how quickly available capacity has been declining. The guide leaves out the estimate when headroom is flat or rising. That distinction matters for bare-metal teams deciding when to order more nodes: the result is a projection from the observed trend, not a procurement deadline.
Measure memory before changing requests
A VM’s pod request includes guest memory and estimated overhead for QEMU and other launcher processes. The guide’s dashboards distinguish guest memory use from that overhead, and a companion alert flags when the measured launcher overhead exceeds the estimate. Overcommit carries different consequences for CPU and memory: under contention, CPU overcommit can slow work, while memory exhaustion can kill a workload and force a restart.
Start by checking that the dashboard’s node-loss allowance matches the cluster’s maintenance assumptions. Then use the memory views to check whether guests peak together before treating historical usage as a sizing guide. The article shows how correlated demand changes the overcommit estimate and warns that batch workloads may not follow the normal distribution used in one of its models. Validate any recommendation with the cluster’s own workload before lowering requests.
sources
comments · 0