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

Check whether replicas are all on the same node #143

Open
marians opened this issue Nov 4, 2020 · 1 comment
Open

Check whether replicas are all on the same node #143

marians opened this issue Nov 4, 2020 · 1 comment
Labels
enhancement New feature or request

Comments

@marians
Copy link
Contributor

marians commented Nov 4, 2020




Is your feature request related to a problem? Please describe.

One of the common use cases for running a container orchestrator is the possibility to increase the availability of workloads by spreading replicas over several nodes. However, by default, the Kubernetes scheduler does not take distribution of risk into account. So it can happen that all replicas of a Deployment or StatefulSet run on the same node. A node failure in this case would lead to complete unavailability of the workload/service.

Users can achieve distribution across nodes by setting appropriate anti-affinity settings for pods

Describe the solution you'd like

Popeye should issue a warning if there is a StatefulSet or Deployment with all replicas on the same node. The warning text should mention configuring anti-affinity as a way to mitigate. Example:

All pods on the same node. Consider setting anti-affinity.

Describe alternatives you've considered

The solution above looks at the symptom and may or may not catch the problem, depending on the distribution of pods in the moment of checking.

Parsing the pods's .spec.affinity and trying to deduct whether it would lead to distribution over nodes would solve this in theory. However, that appears way too complex.

Additional context

n/a

@marians
Copy link
Contributor Author

marians commented Feb 26, 2021

PR #149 attempts to close this issue and is ready for review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants