You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For some features, kubelet checks if the underlying runtime supports such features and reject the pod if necessary. One example is the sysctl support. Right now, kubelet simply checks if (1) the runtime is docker, and (2) if docker version is higher than the minimum requirement. With CRI, checking runtime versions directly is no longer viable. One way to solve this is to ask runtime to expose a set of features it supports through CRI. E.g., an Info call can be added to CRI to retrieve a list of supported features.
Note: sysctl is still an experimental feature and relies on pod annotations in the k8s API. However, the pod admission logic is already live in kubelet.
Do we need this as an explicit API? Why not just pass sysctl to the
runtime, and if it doesn't support them, it can either reject the request
or log-and-run-anyway...
Do we need this as an explicit API? Why not just pass sysctl to the
runtime, and if it doesn't support them, it can either reject the request
or log-and-run-anyway...
@thockin One benefit is failing early before calling runtime API if features are not supported.
@yifan-gu Do you mean extend Version() API to include features? I think that's better than adding a new API.
Not saying including features in versions. My thought is the version itself is sufficient to provide information on what features are supported or not (e.g. docker 1.1x support feature a, b, c, etc)
Once the runtime tells us the version, we can infer what features are supported or not, right?
Not saying including features in versions. My thought is the version itself is sufficient to provide information on what features are supported or not (e.g. docker 1.1x support feature a, b, c, etc)
@yifan-gu Versions of different runtime mean different things. if we just let runtime return its version, kubelet must have some runtime specific logic to figure out what docker 1.1x supports, what rkt 1.0x supports etc.
@yifan-gu Versions of different runtime mean different things. if we just let runtime return its version, kubelet must have some runtime specific logic to figure out what docker 1.1x supports, what rkt 1.0x supports etc.
Do we need this as an explicit API? Why not just pass sysctl to the
runtime, and if it doesn't support them, it can either reject the request
or log-and-run-anyway...
Do we need this as an explicit API? Why not just pass sysctl to the
runtime, and if it doesn't support them, it can either reject the request
or log-and-run-anyway...
kubelet right now "rejects" a pod if the runtime doesn't support sysctl. To achieve the same effect, we'll need to either a) ask runtime to return a list of supported features or b) add a new "error" indicating the pod is not supported so that kubelet can reject the pod.
Handling version skew explicitly. If sysctl is added to version 1.1, an older server/runtime, e.g., 1.0, would simply ignore the newly added fields and not return errors. This means that kubelet will have to check what CRI version the runtime is using and whether a particular feature is supported in this version.
Do we need this as an explicit API? Why not just pass sysctl to the
runtime, and if it doesn't support them, it can either reject the request
or log-and-run-anyway...
kubelet right now "rejects" a pod if the runtime doesn't support sysctl. To achieve the same effect, we'll need to either a) ask runtime to return a list of supported features or b) add a new "error" indicating the pod is not supported so that kubelet can reject the pod.
This is what I was thinking
Handling version skew explicitly. If sysctl is added to version 1.1, an older server/runtime, e.g., 1.0, would simply ignore the newly added fields and not return errors. This means that kubelet will have to check what CRI version the runtime is using and whether a particular feature is supported in this version.
Kubelet should NOT be checking versions of plugins. It must be
neutral. The question is which behavior is correct? Rejecting pods
that use unsupported features or ignoring the features? Note this has
implications for defaulting logic, too. If we reject, we can never
default a new field lest we risk the kubelet rejecting it with version
skew (which empirically is the normal state of many clusters).
Can we somehow close the loop? Maybe pass back the runtime's pod, then do
a diff or something? I guess I am OK with feature flags, but I am worried
about the defaulting problem.
#64005 is adding a similar GetRuntimeConfigInfo() interface in CRI, which returns the UID/GID mapping config of runtimes. This could be combined together in one info API.
Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.
If this issue is safe to close now please do so with /close.
Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle stale
Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.
If this issue is safe to close now please do so with /close.
Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle rotten
Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.
Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/close
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/test-infra repository.
Activity
yifan-gu commentedon Sep 15, 2016
@yujuhong Why checking runtime versions is not viable?
feiskyer commentedon Sep 16, 2016
+1 for this.
@yifan-gu Do you mean extend
Version()API to include features? I think that's better than adding a new API.thockin commentedon Sep 16, 2016
Do we need this as an explicit API? Why not just pass sysctl to the
runtime, and if it doesn't support them, it can either reject the request
or log-and-run-anyway...
On Thu, Sep 15, 2016 at 8:34 PM, Pengfei Ni notifications@github.com
wrote:
feiskyer commentedon Sep 16, 2016
@thockin One benefit is failing early before calling runtime API if features are not supported.
yifan-gu commentedon Sep 16, 2016
Not saying including features in versions. My thought is the version itself is sufficient to provide information on what features are supported or not (e.g. docker 1.1x support feature a, b, c, etc)
Once the runtime tells us the version, we can infer what features are supported or not, right?
Random-Liu commentedon Sep 16, 2016
@yifan-gu Versions of different runtime mean different things. if we just let runtime return its version, kubelet must have some runtime specific logic to figure out what docker 1.1x supports, what rkt 1.0x supports etc.
yifan-gu commentedon Sep 16, 2016
Fair enough.
thockin commentedon Sep 17, 2016
I am not sure that is a compelling enough reason on its own.
On Sep 15, 2016 8:45 PM, "Pengfei Ni" notifications@github.com wrote:
yujuhong commentedon Sep 19, 2016
sysctlis added to version 1.1, an older server/runtime, e.g., 1.0, would simply ignore the newly added fields and not return errors. This means that kubelet will have to check what CRI version the runtime is using and whether a particular feature is supported in this version.thockin commentedon Sep 19, 2016
On Mon, Sep 19, 2016 at 2:38 PM, Yu-Ju Hong notifications@github.com wrote:
This is what I was thinking
Kubelet should NOT be checking versions of plugins. It must be
neutral. The question is which behavior is correct? Rejecting pods
that use unsupported features or ignoring the features? Note this has
implications for defaulting logic, too. If we reject, we can never
default a new field lest we risk the kubelet rejecting it with version
skew (which empirically is the normal state of many clusters).
yujuhong commentedon Sep 19, 2016
Ignoring features may be ok in some cases, and I think this is what we do in k8s today (older kubelets ignore new features).
On the other hand, if the feature is related to security (e.g., apparmor?), letting the runtime silently ignore it seems dangerous.
thockin commentedon Sep 19, 2016
Can we somehow close the loop? Maybe pass back the runtime's pod, then do
a diff or something? I guess I am OK with feature flags, but I am worried
about the defaulting problem.
On Mon, Sep 19, 2016 at 4:23 PM, Yu-Ju Hong notifications@github.com
wrote:
38 remaining items
feiskyer commentedon May 29, 2018
@jessfraz Any comments on this?
jessfraz commentedon May 29, 2018
Yeah I think /info or something like it should return so the admission controllers can deny or not for features like they do with docker versions
feiskyer commentedon May 29, 2018
#64005 is adding a similar
GetRuntimeConfigInfo()interface in CRI, which returns the UID/GID mapping config of runtimes. This could be combined together in one info API.feiskyer commentedon May 29, 2018
@yujuhong @Random-Liu @mikebrow @mrunalp For the list of features, any more ideas of this list:
fejta-bot commentedon Aug 27, 2018
Issues go stale after 90d of inactivity.
Mark the issue as fresh with
/remove-lifecycle stale.Stale issues rot after an additional 30d of inactivity and eventually close.
If this issue is safe to close now please do so with
/close.Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle stale
fejta-bot commentedon Sep 26, 2018
Stale issues rot after 30d of inactivity.
Mark the issue as fresh with
/remove-lifecycle rotten.Rotten issues close after an additional 30d of inactivity.
If this issue is safe to close now please do so with
/close.Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/lifecycle rotten
fejta-bot commentedon Oct 26, 2018
Rotten issues close after 30d of inactivity.
Reopen the issue with
/reopen.Mark the issue as fresh with
/remove-lifecycle rotten.Send feedback to sig-testing, kubernetes/test-infra and/or fejta.
/close
k8s-ci-robot commentedon Oct 26, 2018
@fejta-bot: Closing this issue.
Details
In response to this:
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/test-infra repository.
Merge pull request kubernetes#34830 from feiskyer/sysctl
chore(cli): generate conversion from cdk.json to cli arguments (kuber…