More

Vertical autoscaling (shturval-vpa)

About the service

ParameterValue
GUI nameVPA Operator
System name (identifier)shturval-vpa
Cluster assignmentCalculates recommendations and vertically autoscales container CPU and Memory requests and limits.
CriticalNo
BundleMain
Public repositoryVertical Pod Autoscaler
DependenciesRecommendation calculation requires resource usage metrics. In the platform, shturval-metrics-collector collects them.

Purpose

shturval-vpa installs Vertical Pod Autoscaler (VPA) in the cluster. VPA analyzes CPU and Memory usage, calculates recommended container requests and limits, and applies them to pods according to the policy.

VPA does not change the number of workload replicas. Use HPA for horizontal autoscaling. To keep HPA and VPA from competing, do not configure them to manage the same resources.

The service is installed in the cluster in a disabled state. To start using VPA, enable shturval-vpa on the Installed services page. Until the service is enabled and reaches a working state, VPA management in Deployment and StatefulSet is unavailable.

After you enable the service, it creates the VerticalPodAutoscaler and VerticalPodAutoscalerCheckpoint CRDs in the autoscaling.k8s.io group and starts three components:

ComponentPurpose
recommenderAnalyzes resource usage and writes recommendations to the status of the VerticalPodAutoscaler object.
updaterApplies recommendations to running pods according to the update policy. To do this, it can change a pod or start its eviction.
admission-controllerApplies recommendations when a pod is created, through a mutating webhook.

The service does not create VerticalPodAutoscaler objects. Configure VPA for the required workload in the GUI or apply a manifest. For details, see Modify and scale: VPA.

Enabling and management

  1. In the cluster, go to Services and repositories → Installed services.
  2. Find shturval-vpa and enable the service.
  3. Wait until the service reaches a working state.

VPA management then becomes available on the Deployment and StatefulSet pages. If shturval-vpa is not in the list of installed services, install the chart with the same name on the Available charts page.

To view the configuration, open shturval-vpa on the Installed services page and click Manage. To change parameters of the running service, apply a ShturvalServicePatch (SSP).

Main parameters

After the service is enabled, all three components are active by default.

ParameterDefaultDescription
admissionController.enabledtrueStarts the admission controller, the webhook Service, and the related objects.
recommender.enabledtrueStarts the recommender that calculates recommendations.
recommender.replicas2Number of recommender replicas. With two or more replicas, leader election is used automatically when leaderElection.enabled is not set.
updater.enabledtrueStarts the updater that applies recommendations to running pods.
updater.replicas2Number of updater replicas. Leader election follows the same rule as for the recommender.
certGen.enabledtrueIssues the TLS certificate and configures the mutating webhook with helper Jobs.
certManager.enabledfalseUses cert-manager for the webhook certificate. Do not enable this mode together with certGen.enabled.
admissionController.tls.createfalseCreates a Secret from the certificate and key set in the service parameters. This mode alone does not create the webhook.

Do not enable several webhook and certificate modes at the same time. For example, certGen.enabled is incompatible with certManager.enabled and registerWebhook: true. Helm does not deploy the service when the configuration is incompatible.

Troubleshooting

ProblemWhat to check
VPA management is unavailable for a workloadshturval-vpa is enabled on the Installed services page and is in a working state.
Recommendations are not calculatedrecommender is running, and the cluster collects CPU and Memory metrics with shturval-metrics-collector.
Recommendations exist but are not appliedupdater is running; the VPA update mode allows recommendations to be applied; the workload has enough live replicas for pod eviction.
Recommendations are not applied when a pod is createdadmission-controller, the vpa-webhook Service, and MutatingWebhookConfiguration are running; the Secret with the TLS certificate is available.

For workload checks, see VPA does not calculate recommendations.


To deploy the service manually, see How to deploy a new service.