Skip to content

Commit 94d61b2

Browse files
authored
Update k8s-best-practices-requests-limits.adoc
1 parent b19671f commit 94d61b2

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

modules/k8s-best-practices-requests-limits.adoc

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Kubernetes provides mechanisms for defining resource usage per container:
66
* *Limits*: The maximum amount a container is allowed to consume. Enforced by the kubelet.
77
* *Quotas*: Enforce aggregate resource usage at the namespace/project level to prevent resource overuse.
88
9-
See: _OpenShift Resource Quotas Per Project_
9+
See: link:https://docs.openshift.com/container-platform/latest/nodes/clusters/nodes-cluster-resource-configure.html#nodes-cluster-resource-configure-resource-quotas_nodes-cluster-resource-configure[OpenShift Resource Quotas Per Project]
1010

1111
== Risks with Resource Limits
1212

@@ -59,11 +59,21 @@ Kubernetes treats resources differently depending on their behavior under pressu
5959
* *Compressible (e.g., CPU)*: Requests should be balanced to ensure proportional system behavior and fairness.
6060
* *Incompressible (e.g., memory)*: Requests should reflect minimum safe usage to avoid runtime failure.
6161

62-
See: _More details on setting requests for different resource types_
62+
See: link:https://kubernetes.io/docs/concepts/configuration/manage-resources-containers/#resource-units-in-kubernetes[More details on setting requests for different resource types]
6363

6464
== Alternatives to Resource Limits
6565

6666
Although limits are generally avoided for cluster components, the following mechanisms can help manage resources and prioritize workloads:
6767

6868
* *Pod Priority (PriorityClass)*: Preferred for ensuring essential core workloads have priority and sufficient resources.
69-
** Allows critical components to avoid eviction during resource press**
69+
** Allows critical components to avoid eviction during resource pressure.
70+
** More effective than limits, as kubelet's eviction does not consider limits.
71+
* *Quotas*: Can enforce requests and limits at the project level.
72+
** Useful when guaranteed capacity is needed.
73+
** Overcommitment trade-offs can be managed at the project, node, or cluster level.
74+
75+
== Overcommitment
76+
77+
Nodes can be overcommitted, influencing how requests and limits are applied.
78+
79+
* Overcommitted clusters often experience pod kills and kubelet restarts, degrading the product exp*

0 commit comments

Comments
 (0)