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

fix: remove --containerd Kubelet cAdvisor arg. #835

Merged
merged 1 commit into from
Nov 24, 2024

Conversation

aznashwan
Copy link
Contributor

@aznashwan aznashwan commented Nov 22, 2024

This patch stops passing the --containerd argument (value should be path to containerd socket) to kubelet.

This argument's backstory is a bit of a doozy but I'll try to lay it out:

Thus, this setting does not SEEM to be relevant for the k8s-snap.
The actual containerd socket is correctly passed as the --container-runtime-endpoint right above it FWIW.

I am unfortunately unsure why its presence is producing the POST /k8sd/cluster: Post "http://control.socket/1.0/k8sd/cluster": EOF error on k8s bootstrap we've been seeing, but I can vouch from my manual testing that removing it works around that particular crash

@aznashwan aznashwan requested a review from a team as a code owner November 22, 2024 21:32
@addyess
Copy link
Contributor

addyess commented Nov 22, 2024

thanks @aznashwan -- might need a bit more description here. But i understand why we don't need this argument

@eaudetcobello
Copy link
Contributor

Is it not needed, or is it in use but deprecated?

@aznashwan aznashwan force-pushed the remove-kubelet-containerd-arg branch 2 times, most recently from 7411a7f to cebb1e1 Compare November 23, 2024 12:14
@aznashwan aznashwan changed the title fix: remove redundant --containerd argument from kubelet. fix: remove --containerd Kubelet cAdvisor arg. Nov 23, 2024
This patch removes the passing of the `--containerd` argument
(value should be path to containerd socket) to `kubelet`.

This argument is actually not a kubelet argument per se, but instead it
is a cAdvisor argument (1) which was accidentally transparently declared
and shipped in kubelet a very long time ago, but had been explicitly
declared within kubelet and marked deprecated since 2017 (2).

[1] https://github.com/google/cadvisor/blob/3888dda254a8fa12f1c96be24ffdc33288ea9071/container/containerd/factory.go#L34
[2] https://github.com/kubernetes/kubernetes/pull/57613/files#diff-fecc7baa0b61f11d37dfc453aef25acca98866e1924f7765ba5592ca58fc3045R143

Signed-off-by: Nashwan Azhari <[email protected]>
Copy link
Contributor

@bschimke95 bschimke95 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for the investigation.

@bschimke95 bschimke95 merged commit 2de1a9a into canonical:main Nov 24, 2024
17 checks passed
bschimke95 pushed a commit that referenced this pull request Nov 24, 2024
This patch removes the passing of the `--containerd` argument
(value should be path to containerd socket) to `kubelet`.

This argument is actually not a kubelet argument per se, but instead it
is a cAdvisor argument (1) which was accidentally transparently declared
and shipped in kubelet a very long time ago, but had been explicitly
declared within kubelet and marked deprecated since 2017 (2).

[1] https://github.com/google/cadvisor/blob/3888dda254a8fa12f1c96be24ffdc33288ea9071/container/containerd/factory.go#L34
[2] https://github.com/kubernetes/kubernetes/pull/57613/files#diff-fecc7baa0b61f11d37dfc453aef25acca98866e1924f7765ba5592ca58fc3045R143

Signed-off-by: Nashwan Azhari <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants