Vmware Slot Size Calculation
By Duncan Epping, Principal Architect, VMware
Yesterday I received a question on twitter:
Hi, to settle an argument in the office, if no reserves are in place, does number of vCPU’s affect slot size in vSphere 4? Thx 🙂
- Use a calculator. They are all valid in some form or the other and have their specific purpose. I think it basically doesn’t matter if you’re sizing NSX, sizing vSphere or sizing another VMware product, if you use the methods above you get a infrastructure that is able to run your workload.
- Slot size is calculated by comparing both the CPU and memory requirements of the virtual machines and selecting the largest. The largest CPU requirement (shared by VM1 and VM2) is 2GHz, while the largest memory requirement (for VM3) is 2GB. Based on this, the slot size is 2GHz CPU and 2GB memory.
Vmware Slot Size Calculation Chart
A slot represents the minimum CPU and memory resources that are required to support any powered-on virtual machine in the cluster. With the failover level policy in place, HA uses the following slot calculations to control virtual machine migration within the cluster: Calculate the slot size from CPU and memory reservations.
First of all, what is a slot? The availability guide explains it as follows
A slot is a logical representation of the memory and CPU resources that satisfy the requirements for any powered-on virtual machine in the cluster.
In other words a slot is the worst case CPU and Memory reservation scenario for any given virtual machine in a cluster. This slot is used when Admission Control is enabled and “Host Failures Tolerates” has been selected as the admission control policy. The total amount of available resources in the cluster will be divided by the slot size and that dictates how many VMs can be powered on without violating availability constraints. Meaning that it will guarantee that every powered on virtual machine can be failed over.
As said this slot is dictated by the worst case reservation for CPU and Memory. Prior to vSphere 4.0 we used the number of vCPUs to determine the slotsize for CPU as well. But we do not use vCPUs anymore to determine the slot size for CPU. The slotsize for CPU is determined by the highest reservation or 256MHz (vSphere 4.x and prior) / 32MHz (vSphere 5) if no reservation is set.
However, vCPUs can have an impact on your slot… it can have an impact on your memory slotsize. If no reservation is set anywhere HA will use the highest Memory Overhead in your cluster as the slot size for memory. This is where the amount of vCPUs come in to play, the more vCPUs you add to a virtual machine the higher will your memory overhead be.
Vmware Ha Slot Size Calculation
I guess the answer to this question is: For CPU the number of vCPUs does not impact your slotsize, but for memory it may.
vSphere HA uses admission control to ensure that sufficient resources are reserved for virtual machine recovery when a host fails.
Admission control imposes constraints on resource usage. Any action that might violate these constraints is not permitted. Actions that might be disallowed include the following examples:
- Powering on a virtual machine
- Migrating a virtual machine
- Increasing the CPU or memory reservation of a virtual machine
- Cluster resource percentage
- Slot policy
- Dedicated failover hosts
Regardless of the admission control option chosen, a VM resource reduction threshold also exists. You use this setting to specify the percentage of resource degradation to tolerate, but it is not available unless vSphere DRS is enabled.
The resource reduction calculation is checked for both CPU and memory. It considers a virtual machine's reserved memory and memory overload to decide whether to permit it to power on, migrate, or have reservation changes. The actual memory consumed by the virtual machine is not considered in the calculation because the memory reservation does not always correlate with the actual memory usage of the virtual machine. If the actual usage is more than reserved memory, insufficient failover capacity is available, resulting in performance degradation on failover.
Setting a performance reduction threshold enables you to specify the occurrence of a configuration issue. For example:
Vmware Slot Size Calculation Tool
- The default value is 100%, which produces no warnings.
- If you reduce the threshold to 0%, a warning is generated when cluster usage exceeds the available capacity.
- If you reduce the threshold to 20%, the performance reduction that can be tolerated is calculated as performance reduction = current utilization * 20%. When the current usage minus the performance reduction exceeds the available capacity, a configuration notice is issued.