Kubeturbo resource limits
By default, Kubeturbo deploys without limits or requests. If you
prefer to set limits or requests, the amount of resources required for Kubeturbo is related
to the number of workloads and pods that it manages. A workload is defined as a unique workload controller, such as deployment
foo
and statefulset bar
.
After you deploy Kubeturbo, you can view the number of workloads in the Turbonomic supply chain. Set the scope to a single container platform cluster and then view the Workload Controller entity.
Kubeturbo discovers, collects, and processes metrics for container platform resources every one minute and then sends the data to Turbonomic for analysis every 10 minutes. Since data is collected every one minute, Kubeturbo holds the data in memory consistently.
Use the following table as a guide for setting memory limits:
Number of pods | Number of workload controllers | Recommended memory limit (Gi) |
---|---|---|
5,000 | 2,500 | 4 |
5,000 | 5,000 | 4 |
10,000 | 5,000 | 6 |
10,000 | 10,000 | 6.5 |
20,000 | 10,000 | 9.2 |
20,000 | 20,000 | 12 |
30,000 | 15,000 | 13 |
30,000 | 30,000 | 16 |
Points to consider:
-
To avoid CPU throttling, do not set a CPU limit.
-
If needed, memory requests can be set to 1 GB.
-
If needed, CPU requests can be set to 1 core (1000 millicores).
-
If Kubeturbo memory usage is very high and consistently growing over time, set a limit that is lower than the node memory capacity to limit the memory usage. Refer to the preceding table for guidance.
-
To configure Kubeturbo container spec limits and requests, see the next sections.
YAML configuration: Kubeturbo container spec limit and request
-
Edit the deployment.
kubectl edit deployment kubeturbo -n turbo
-
In the
containers
section, find and update theresources: {}
section as shown in the following example:resources: limits: memory: 16Gi requests: memory: 1Gi
If the section does not exist, create it as described.
-
Save the changes.
The
kubeturbo
pod restarts with the changes applied automatically. -
Verify the changes.
kubectl get pods -n turbo -o custom-columns='NAME:.metadata.name,MEMORY_REQ:spec.containers[].resources.requests.memory,MEM_LIM:spec.containers[].resources.limits.memory'
The output should be similar to the following example. This output confirms that the memory limit and request was set correctly for
kubeturbo
.NAME MEMORY_REQ MEM_LIM
kubeturbo-6cbfc74b68-dfvtk 1Gi 16Gi
Operator configuration: Kubeturbo container spec limit and request
-
Edit the deployment.
kubectl edit kubeturbo kubeturbo-release -n turbo
-
In the
spec
section, find and update theresources: {}
section as shown in the following example.resources: limits: memory: 16Gi requests: memory: 1Gi
If the section does not exist, create it as described.
-
Save the changes.
The
kubeturbo-release
pod restarts with the changes applied automatically. -
Verify the changes.
kubectl get pods -n turbo -o custom-columns='NAME:.metadata.name,MEMORY_REQ:spec.containers[].resources.requests.memory,MEM_LIM:spec.containers[].resources.limits.memory'
Verify that the output is similar to the following example. This output confirms that the memory limit and request was set correctly for
kubeturbo-release
.NAME MEMORY_REQ MEM_LIM
kubeturbo-release-6cbfc74b68-dfvtk 1Gi 16Gi