0

I am looking for a way (Kubernetes API/Command) that returns a list of worker nodes associated to the same master node. I have been digging clues on Google for days but to no avail.

I have tried to look into details of every worker node using "kubectl describe nodes" but none of the options indicate any relationship between the worker node and master node.

I expect something like a list of Worker Node A, Worker Node B and Worker Node C returns when I input the common master node.

Debugger
  • 494
  • 5
  • 18
JH G
  • 1
  • 2
  • https://stackoverflow.com/questions/52941015/how-to-find-master-node-from-worker-node-in-kubernetes – Ijaz Ahmad Jul 12 '19 at 08:56
  • Possible duplicate of [How to find master node from worker node in Kubernetes](https://stackoverflow.com/questions/52941015/how-to-find-master-node-from-worker-node-in-kubernetes) – Nepomucen Jul 12 '19 at 11:23

1 Answers1

1

In scenario with more than one master, the Kubernetes make leader selection so the other masters stays inactive.

You can use endpoints to check who the master is.