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

MHC Controller keeps issuing warning although the MachineDeployment does not have any unhealthy machines #10585

Closed
Levi080513 opened this issue May 10, 2024 · 4 comments
Labels
area/machinehealthcheck Issues or PRs related to machinehealthchecks kind/bug Categorizes issue or PR as related to a bug. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. triage/accepted Indicates an issue or PR is ready to be actively worked on.

Comments

@Levi080513
Copy link
Contributor

What steps did you take and what happened?

  1. Create CAPI Cluster.
  2. Create MHC and configure unHealthRange like this
spec:
  clusterName: hw-sks-test-logging
  maxUnhealthy: 100%
  nodeStartupTimeout: 5m0s
  selector:
    matchLabels:
      cluster.x-k8s.io/cluster-name: hw-sks-test-logging
      cluster.x-k8s.io/deployment-name: hw-sks-test-logging-logging
  unhealthyConditions:
  - status: Unknown
    timeout: 5m0s
    type: Ready
  - status: "False"
    timeout: 5m0s
    type: Ready
  unhealthyRange: '[1-3]'
  1. MHC Controller keeps issuing warning although the cluster does not have any unhealthy machines, the warning events like this:
3m52s       Warning   RemediationRestricted   machinehealthcheck/hw-sks-test-logging-logging     Remediation is not allowed, the number of not started or unhealthy machines does not fall within the range (total: 3, unhealthy: 0, unhealthyRange: [1-3])

What did you expect to happen?

Can we make a small optimization for the MHC Controller does not generate this warning when the MachineDeployment does not have any unhealthy machines? This is easily misleading.

Cluster API version

v1.6.4

Kubernetes version

v1.25.16

Anything else you would like to add?

No response

Label(s) to be applied

/kind bug
One or more /area label. See https://github.com/kubernetes-sigs/cluster-api/labels?q=area for the list of labels.

@k8s-ci-robot k8s-ci-robot added kind/bug Categorizes issue or PR as related to a bug. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels May 10, 2024
@sbueringer
Copy link
Member

Sounds good!

@enxebre
Copy link
Member

enxebre commented May 13, 2024

/kind cleanup
/area machinehealthcheck
/triage accepted

@k8s-ci-robot k8s-ci-robot added kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. area/machinehealthcheck Issues or PRs related to machinehealthchecks triage/accepted Indicates an issue or PR is ready to be actively worked on. and removed needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels May 13, 2024
@fabriziopandini
Copy link
Member

/close
The PR already merged

@k8s-ci-robot
Copy link
Contributor

@fabriziopandini: Closing this issue.

In response to this:

/close
The PR already merged

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/machinehealthcheck Issues or PRs related to machinehealthchecks kind/bug Categorizes issue or PR as related to a bug. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. triage/accepted Indicates an issue or PR is ready to be actively worked on.
Projects
None yet
Development

No branches or pull requests

5 participants