Vertical Scaling

Kubernetes Cluster: Vertical Scaling

Vertical scaling for a Kubernetes Cluster is handled at two levels: the platform can dynamically allocate resources to Kubernetes nodes, while Kubernetes can adjust CPU and memory requirements for individual pods through the Vertical Pod Autoscaler (VPA).

Two Vertical Scaling Approaches

Platform-Managed Scaling Automatically allocates additional resources to Kubernetes nodes when they are needed.
Kubernetes-Managed VPA Adjusts pod CPU and memory requests and limits dynamically according to workload requirements.

Platform-Managed Vertical Scaling

Automatic vertical scaling at the platform level dynamically allocates resources to Kubernetes nodes as workload demand changes.

  • Resources are allocated when the node actually needs them.
  • The platform charges for resources based on actual consumption rather than the maximum configured limit.
  • This allows Kubernetes nodes to accommodate temporary or growing workloads without permanently reserving all possible CPU and memory.
Platform vertical scaling works at the Kubernetes node level. It increases or decreases the resources available to the node itself rather than directly changing the resource requests of an individual Kubernetes pod.

Kubernetes Vertical Pod Autoscaler

The Kubernetes Vertical Pod Autoscaler (VPA) operates inside Kubernetes and adjusts the CPU and memory requests and limits assigned to pods.

  • VPA analyzes pod resource usage.
  • It can recommend or apply updated CPU and memory values.
  • This helps avoid consistently over-provisioned or under-provisioned pod resource settings.
Status: The source documentation identifies Kubernetes Vertical Pod Autoscaler as a beta feature. Review compatibility and behavior for the Kubernetes version used by your cluster before enabling it for production workloads.

Combining Both Approaches

The strongest resource-efficiency model is achieved when platform-level vertical scaling and Kubernetes VPA are used together.

Pod Level VPA helps each pod request a more suitable amount of CPU and memory.
Node Level The platform dynamically provides the resources required by the Kubernetes nodes.
Cost Efficiency Better resource matching can reduce unused capacity and lower cluster maintenance costs.
Resilience Dynamic resource allocation helps workloads remain available as demand changes.
The source documentation also references an extended WordPress use case that demonstrates Kubernetes Cluster scaling in a practical workload scenario.
Vertical scaling summary: Use platform automatic vertical scaling to dynamically expand Kubernetes node resources, and use VPA when pod CPU and memory requests also need to adapt to workload demand.

What’s next?