-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
KEP-4471: kubeadm: make a control-plane's kubelet talk to the local API Server on kubeadm join. #4496
Conversation
chrischdi
commented
Feb 8, 2024
- One-line PR description: adding new KEP
- Issue link: kubeadm: make a control-plane's kubelet talk to the local API Server on kubeadm join. #4471
- Other comments:
cc @neolit123 @fabriziopandini @sbueringer :-) PTAL |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
i will have a look tomorrow.
FYI: I'm on PTO the next days and will be back on 15th. Will start addressing feedback then :-) |
Sounds reasonable overall, but Fabrizio and Lubomir are way more familiar with the kubeadm details |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks @chrischdi
i did a first pass and the KEP seems good, minus some typos and some missing minor clarifications.
keps/sig-cluster-lifecycle/kubeadm/4471-cp-join-kubelet-local-apiserver/README.md
Outdated
Show resolved
Hide resolved
keps/sig-cluster-lifecycle/kubeadm/4471-cp-join-kubelet-local-apiserver/README.md
Outdated
Show resolved
Hide resolved
keps/sig-cluster-lifecycle/kubeadm/4471-cp-join-kubelet-local-apiserver/README.md
Outdated
Show resolved
Hide resolved
keps/sig-cluster-lifecycle/kubeadm/4471-cp-join-kubelet-local-apiserver/README.md
Outdated
Show resolved
Hide resolved
keps/sig-cluster-lifecycle/kubeadm/4471-cp-join-kubelet-local-apiserver/README.md
Outdated
Show resolved
Hide resolved
keps/sig-cluster-lifecycle/kubeadm/4471-cp-join-kubelet-local-apiserver/README.md
Outdated
Show resolved
Hide resolved
keps/sig-cluster-lifecycle/kubeadm/4471-cp-join-kubelet-local-apiserver/README.md
Outdated
Show resolved
Hide resolved
keps/sig-cluster-lifecycle/kubeadm/4471-cp-join-kubelet-local-apiserver/README.md
Outdated
Show resolved
Hide resolved
keps/sig-cluster-lifecycle/kubeadm/4471-cp-join-kubelet-local-apiserver/README.md
Outdated
Show resolved
Hide resolved
keps/sig-cluster-lifecycle/kubeadm/4471-cp-join-kubelet-local-apiserver/README.md
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pointing the control-plane's kubelet to the local kube-apiserver may cause some stability issues. When kube-apiserver fails, the local kubelet will crash, and the node will become NotReady, the entire control-plane node cannot handle the new Pod. However, using LB will not cause the entire control-plane node to be NotReady, just some components can not work well. When |
I agree, I will add that information. An improvement may be to only use the local endpoint during TLS Bootstrap and make kubeadm change the config afterwards back to the load balancer 🤔
In case of immutable upgrades (e.g. Cluster API) where you update the whole image and the image contains the binary versions: when correctly following the version skew you would have to (example: v1.x -> v1.y):
And upgrade via:
Everyone nowadays skips step 1 with CAPI (because normally it works). |
this is something that i mentioned/asked on the kubeadm office hours zoom call we had. currently with a kubelet pointing at the LB if a local apiserver fails (e.g. due to an internal apiserver bug) the kubelet will try to find a healthy kube-apiserver and the Node will remain healthy, while in parallel it will try to restart the local filing pod. with the new way if the apiserver fails the node will become not ready.
bootstrap to local apiserver makes sense. i was thinking that maybe we can let the user control this behavior with an option in the config API. i personally don't like this idea, but it can be added in v1beta4 if people vote +1 for that. alternatively, the default behavior can be - point to local, but they can manually edit to point to LB if they want more HA. |
01acae6
to
963bd7b
Compare
@SataQiu @pacoxu any more comments here?
still not a fan of making it configurable as pointing to the LB can violate kubelet / apiserver skew, but to make it configurable by kubeadm we can do one of these things:
my vote goes to 3. EDIT: and yes we should still have a FG while the feature graduates. |
also vote to 3 Just like FYI: It seems that kubeadm just configures kubelet, but not restart the kubelet service. We can state in the documentation that please restart the kubelet service in turn after all the control-plane instances have been upgraded. |
👍
upgrade does not touch "etc/kubernetes/kubelet.conf" today, so if the user modifies the "server" in there it will persist.
yes, a kubelet restart will be required. |
IIUC,
vote to 2 and 3. |
we can say it's a bug fix for potential skew problems that introduces a change in behavior.
we could just document it as our first choice (3), but if users really need better flexibility, we can think about alternatives like 2 or something else. |
keps/sig-cluster-lifecycle/kubeadm/4471-cp-join-kubelet-local-apiserver/kep.yaml
Outdated
Show resolved
Hide resolved
keps/sig-cluster-lifecycle/kubeadm/4471-cp-join-kubelet-local-apiserver/README.md
Show resolved
Hide resolved
3 is ok to go. +1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please squash all commits, then lgtm
/approve
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: chrischdi, neolit123 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/lgtm |