Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OSDOCS-1038: Adding docs for new descheduler policy #22063

Merged
merged 1 commit into from
May 20, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions modules/nodes-descheduler-about.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ You can benefit from descheduling running Pods in situations such as the followi
* Pod and node affinity requirements, such as taints or labels, have changed and the original scheduling decisions are no longer appropriate for certain nodes.
* Node failure requires Pods to be moved.
* New nodes are added to clusters.
* Pods have been restarted too many times.

[IMPORTANT]
====
Expand Down
23 changes: 15 additions & 8 deletions modules/nodes-descheduler-configuring-strategies.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -32,24 +32,31 @@ spec:
strategies:
- name: "LowNodeUtilization" <1>
params:
- name: "cputhreshold"
- name: "CPUThreshold"
value: "10"
- name: "memorythreshold"
- name: "MemoryThreshold"
value: "20"
- name: "podsthreshold"
- name: "PodsThreshold"
value: "30"
- name: "memorytargetthreshold"
- name: "MemoryTargetThreshold"
value: "40"
- name: "cputargetthreshold"
- name: "CPUTargetThreshold"
value: "50"
- name: "podstargetthreshold"
- name: "PodsTargetThreshold"
value: "60"
- name: "nodes"
- name: "NumberOfNodes"
value: "3"
- name: "RemoveDuplicates" <2>
- name: "RemovePodsHavingTooManyRestarts" <3>
params:
- name: "PodRestartThreshold"
bergerhoffer marked this conversation as resolved.
Show resolved Hide resolved
value: "10"
- name: "IncludingInitContainers"
value: "false"
----
<1> The `LowNodeUtilization` strategy provides additional parameters, such as `cputhreshold` and `memorythreshold`, that you can optionally configure.
<1> The `LowNodeUtilization` strategy provides additional parameters, such as `CPUThreshold` and `MemoryThreshold`, that you can optionally configure.
<2> The `RemoveDuplicates`, `RemovePodsViolatingInterPodAntiAffinity`, `RemovePodsViolatingNodeAffinity`, and `RemovePodsViolatingNodeTaints` strategies do not have any additional parameters to configure.
<3> The `RemovePodsHavingTooManyRestarts` strategy requires the `PodRestartThreshold` parameter to be set. It also provides the optional `IncludingInitContainers` parameter.
+
You can enable multiple strategies and the order that the strategies are specified in is not important.

Expand Down
9 changes: 8 additions & 1 deletion modules/nodes-descheduler-strategies.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ The underutilization of nodes is determined by several configurable threshold pa
+
You can also set a target threshold for CPU, memory, and number of Pods. If a node's usage is above the configured target thresholds for all parameters, then the node's Pods might be considered for eviction.
+
Additionally, you can use the `nodes` parameter to set the strategy to activate only when the number of underutilized nodes is above the configured value. This can be helpful in large clusters where a few nodes might be underutilized frequently or for a short period of time.
Additionally, you can use the `NumberOfNodes` parameter to set the strategy to activate only when the number of underutilized nodes is above the configured value. This can be helpful in large clusters where a few nodes might be underutilized frequently or for a short period of time.

Duplicate Pods::
The `RemoveDuplicates` strategy ensures that there is only one Pod associated with a ReplicaSet, ReplicationController, Deployment, or Job running on same node. If there are more, then those duplicate Pods are evicted for better spreading of Pods in a cluster.
Expand All @@ -35,3 +35,10 @@ Violation of node taints::
The `RemovePodsViolatingNodeTaints` strategy ensures that Pods violating `NoSchedule` taints on nodes are removed.
+
This situation could occur if a Pod is set to tolerate a taint `key=value:NoSchedule` and is running on a tainted node. If the node's taint is updated or removed, the taint is no longer satisfied by the Pod's tolerations and the Pod is evicted.

Too many restarts::
The `RemovePodsHavingTooManyRestarts` strategy ensures that Pods that have been restarted too many times are removed from nodes.
+
This situation could occur if a Pod is scheduled on a node that is unable to start it. For example, if the node is having network issues and is unable to mount a networked persistent volume, then the Pod should be evicted so that it can be scheduled on another node. Another example is if the Pod is crashlooping.
+
This strategy has two configurable parameters: `PodRestartThreshold` and `IncludingInitContainers`. If a Pod is restarted more than the configured `PodRestartThreshold` value, then the Pod is evicted. You can use the `IncludingInitContainers` parameter to specify whether restarts for Init Containers should be calculated into the `PodRestartThreshold` value.