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

Karmada-controller-manager stale state #5839

Closed
LavredisG opened this issue Nov 19, 2024 · 9 comments
Closed

Karmada-controller-manager stale state #5839

LavredisG opened this issue Nov 19, 2024 · 9 comments
Labels
kind/question Indicates an issue that is a support question.

Comments

@LavredisG
Copy link
Contributor

LavredisG commented Nov 19, 2024

Please provide an in-depth description of the question you have:
I started with a setup of 2 kind clusters, karmada-host and member1. The former was used both as the host were Karmada was installed, as well as a member cluster. So I had 2 member clusters joined. I also had set kube-prometheus-stack on karmada-host in order to retrieve karmada metrics. More specifically I was scraping karmada-controller-manager. While inspecting the cluster-node-number metric I was getting the expected result.

However, once I deleted member1 cluster, karmada-controller-manager returned info about 2 clusters instead of 1 when querried.

image

image

What do you think about this question?:
Is that expected behavior? Shouldn't karmada-controller-manager observe that 1 cluster has been deleted so that it shouldn't retrieve info about it anymore?

Environment:

  • Karmada version: v1.12.0-alpha.1-36-g13df63fa4
  • Kubernetes version: v1.31.0
  • kubectl: v1.29.0
@LavredisG LavredisG added the kind/question Indicates an issue that is a support question. label Nov 19, 2024
@RainbowMango
Copy link
Member

While inspecting the cluster-node-number metric I was getting the expected result.

Firstly, I don't remember having that metric emitted by the karmada-controller-manager.
Are you sure that's from karmada-controller-manager?

However, once I deleted member1 cluster,

How do you delete the cluster? By karmadactl unjoin or just removed the kind cluster, by a command like kind delete clusters --name=member1?

@LavredisG
Copy link
Contributor Author

I am referring to this one:

image

I first unjoined the cluster and then deleted it from kind. A simple workaround is to delete the controller pod, so that when it gets recreated it picks up the correct state, but I don't know if that's the expected way to do it.

@RainbowMango
Copy link
Member

Oh, I see. That was indeed reported from Karmada.
We didn't clean up the gauge after the cluster was gone.

A simple workaround is to delete the controller pod, so that when it gets recreated it picks up the correct state, but I don't know if that's the expected way to do it.

I think it's not the expected behavior. We need more explore how to fix it.

By the way, how important is the metric to you?

@RainbowMango
Copy link
Member

By the way, let me know if you are going to explore this?

@LavredisG
Copy link
Contributor Author

LavredisG commented Nov 20, 2024

My goal is to create a custom scheduler for karmada, utilizing resource/power/network metrics, but I have not concluded which I will use, so at this point I was just trying to set up connectivity from karmada metrics to Prometheus.

By exploring you mean if I will try to fix it?

@RainbowMango
Copy link
Member

Yeah, I mean if you like you can dig into this issue, find the root cause, then try to fix it :)

@LavredisG
Copy link
Contributor Author

LavredisG commented Nov 20, 2024

Yeah, I mean if you like you can dig into this issue, find the root cause, then try to fix it :)

Unfortanutely, I don't think I have enough time to fix it in the foreseeable future :/
I would appreciate to be informed on any updates on this though!

@RainbowMango
Copy link
Member

That's OK.
Given this issue is part of #5843, let's track it by that issue.
/close
Duplicate of #5843

@karmada-bot
Copy link
Collaborator

@RainbowMango: Closing this issue.

In response to this:

That's OK.
Given this issue is part of #5843, let's track it by that issue.
/close
Duplicate of #5843

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
kind/question Indicates an issue that is a support question.
Projects
None yet
Development

No branches or pull requests

3 participants