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

Ignore unschedulable nodes for eviction decisions #43

Closed

Conversation

concaf
Copy link
Contributor

@concaf concaf commented Nov 25, 2017

This commit makes descheduler ignore the unschedulable nodes from
being considered for taking eviction decisions

@aveshagarwal
Copy link
Contributor

Can one of the admins verify this patch?

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Nov 25, 2017
@ravisantoshgudimetla
Copy link
Contributor

@containscafeine You need to fix the test case and also please look at the new flag node-selector #33, through which you can ignore certain nodes based on labels.

Also, there is a plan in upstream community to replace UnSchedulable field with unschedulable taint and in descheduler we plan to have taint based descheduling.

This commit makes descheduler ignore the unschedulable nodes from
being considered for taking eviction decisions
@k8s-ci-robot k8s-ci-robot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Nov 27, 2017
@concaf
Copy link
Contributor Author

concaf commented Nov 27, 2017

@ravisantoshgudimetla ack, fixed the failing test.

Does it make sense that till the time spec.unschedulable is removed, we use it in descheduler?

@ravisantoshgudimetla
Copy link
Contributor

@containscafeine

Does it make sense that till the time spec.unschedulable is removed, we use it in descheduler?

A readynode in descheduler's context means we have a node on which descheduler could run. Even if the node is unschedulable, it could have some pods running(unless it has been drained) which can cause it to be over highUtilization threshold. In this case, descheduler should run against it.

IOW, descheduler is just a pod evictor. For eviction, we don't need to check if the node is unschedulable.

If you don't want node to be considered by descheduler, you should label the node and ask it to be excluded by descheduler.

@aveshagarwal
Copy link
Contributor

A readynode in descheduler's context means we have a node on which descheduler could run. Even if the node is unschedulable, it could have some pods running(unless it has been drained) which can cause it to be over highUtilization threshold. In this case, descheduler should run against it.

Yes that was the intention to consider unschedulable but ready nodes. However, for LowNodeUtilization strategy, if unschedulable nodes are under utilized, we must ignore them as pods wont be scheduled on them. IOW unschedulable nodes must only be considered for eviction if they are above target utilization but we must not consider unschedulable nodes if they are under low utilization threshold. If it is not the case, we should fix the LowNodeUtilization strategy.

@ravisantoshgudimetla
Copy link
Contributor

Ok after reading #42, I understood @containscafeine wants to do here but I believe the change in code should be in utilization strategy file. I will send a PR soon.

@concaf
Copy link
Contributor Author

concaf commented Nov 28, 2017

Yay, thanks @ravisantoshgudimetla. Closing in favor of #45

@concaf concaf closed this Nov 28, 2017
damemi pushed a commit to damemi/descheduler that referenced this pull request Nov 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants