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

pkg/proxy: only set sysctl if not already set #68760

Merged
merged 1 commit into from Sep 26, 2018

Conversation

@jessfraz
Copy link
Contributor

jessfraz commented Sep 18, 2018

cc @thockin

This will allow for kube-proxy to be run without privileged and
with only adding the capability NET_ADMIN.

NONE

@jessfraz jessfraz changed the title only set sysctl if not already set pkg/proxy: only set sysctl if not already set Sep 18, 2018

@k8s-ci-robot k8s-ci-robot requested review from dcbw and thockin Sep 18, 2018

@jessfraz

This comment has been minimized.

Copy link
Contributor Author

jessfraz commented Sep 18, 2018

/assign @thockin

@jessfraz jessfraz force-pushed the jessfraz:only-set-sysctl-if-not-set branch from 75c7d11 to f6dc646 Sep 18, 2018

@dims

This comment has been minimized.

Copy link
Member

dims commented Sep 19, 2018

@jessfraz so we have to document that the 3 things that needs to be set by say an admin so the GetSysctl succeeds and it does not have to drop down to the SetSysctl

@jessfraz

This comment has been minimized.

Copy link
Contributor Author

jessfraz commented Sep 19, 2018

@dims which doc do you think would be the most appropriate place for operators to see that information and I will add :)

@jessfraz

This comment has been minimized.

Copy link
Contributor Author

jessfraz commented Sep 19, 2018

or maybe the man page? trying to find the best place :)

@dims

This comment has been minimized.

Copy link
Member

dims commented Sep 19, 2018

@jessfraz i can think of 2 options, we can start with the first one and let the cluster-lifecycle do the other one i think

@thockin

This comment has been minimized.

Copy link
Member

thockin commented Sep 19, 2018

/lgtm
/approve

@jessfraz jessfraz added this to the v1.12 milestone Sep 19, 2018

@dims

This comment has been minimized.

Copy link
Member

dims commented Sep 19, 2018

@jessfraz going back through my notes i see that we will hit sysctl for nf_conntrack_max on linux. would NET_ADMIN be enough to set that?

https://cs.k8s.io/?q=nf_conntrack_max&i=nope&files=&repos=kubernetes/kubernetes

jessfraz added a commit to jessfraz/kubernetes.github.io that referenced this pull request Sep 19, 2018

kube-proxy: add info on sysctls
This adds documentation for PR kubernetes/kubernetes#68760

Signed-off-by: Jess Frazelle <acidburn@microsoft.com>
@jessfraz

This comment has been minimized.

Copy link
Contributor Author

jessfraz commented Sep 19, 2018

added docs here :) kubernetes/website#10342

@jessfraz

This comment has been minimized.

Copy link
Contributor Author

jessfraz commented Sep 19, 2018

good catch... will update.

@jessfraz jessfraz force-pushed the jessfraz:only-set-sysctl-if-not-set branch from f6dc646 to ffb4ee2 Sep 19, 2018

@k8s-ci-robot k8s-ci-robot removed the lgtm label Sep 19, 2018

jessfraz added a commit to jessfraz/kubernetes.github.io that referenced this pull request Sep 19, 2018

kube-proxy: add info on sysctls
This adds documentation for PR kubernetes/kubernetes#68760

Signed-off-by: Jess Frazelle <acidburn@microsoft.com>
pkg/proxy: only set sysctl if not already set
This will allow for kube-proxy to be run without `privileged` and
with only adding the capability `NET_ADMIN`.

Signed-off-by: Jess Frazelle <acidburn@microsoft.com>

@jessfraz jessfraz force-pushed the jessfraz:only-set-sysctl-if-not-set branch from ffb4ee2 to f8ba640 Sep 19, 2018

@k8s-ci-robot k8s-ci-robot added size/M and removed size/S labels Sep 19, 2018

@kubernetes kubernetes deleted a comment from k8s-ci-robot Sep 19, 2018

@jessfraz

This comment has been minimized.

Copy link
Contributor Author

jessfraz commented Sep 19, 2018

Now running a full grep might be cool to do the same to kubelet, although I am unsure how many folks run the kubelet in a container, but I will check it out and see if possible and may send another PR for that

jessfraz added a commit to jessfraz/kubernetes.github.io that referenced this pull request Sep 19, 2018

kube-proxy: add info on sysctls
This adds documentation for PR kubernetes/kubernetes#68760

Signed-off-by: Jess Frazelle <acidburn@microsoft.com>
@jessfraz

This comment has been minimized.

Copy link
Contributor Author

jessfraz commented Sep 19, 2018

/test pull-kubernetes-e2e-kops-aws

@jessfraz jessfraz modified the milestones: v1.12, next-candidate, v1.13 Sep 19, 2018

@jessfraz

This comment has been minimized.

Copy link
Contributor Author

jessfraz commented Sep 19, 2018

added to 1.13 milestone since not critical :)

jessfraz added a commit to jessfraz/kubernetes.github.io that referenced this pull request Sep 19, 2018

kube-proxy: add info on sysctls
This adds documentation for PR kubernetes/kubernetes#68760

Signed-off-by: Jess Frazelle <acidburn@microsoft.com>
@dims

This comment has been minimized.

Copy link
Member

dims commented Sep 19, 2018

@jessfraz yes, redhat folks use containerized kubelet i remember adding a CI test #62508

@dcbw

This comment has been minimized.

Copy link
Member

dcbw commented Sep 20, 2018

/lgtm

@k8s-ci-robot

This comment has been minimized.

Copy link
Contributor

k8s-ci-robot commented Sep 20, 2018

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: dcbw, jessfraz, thockin

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot merged commit 4ca9fa7 into kubernetes:master Sep 26, 2018

18 checks passed

cla/linuxfoundation jessfraz authorized
Details
pull-kubernetes-bazel-build Job succeeded.
Details
pull-kubernetes-bazel-test Job succeeded.
Details
pull-kubernetes-cross Skipped
pull-kubernetes-e2e-gce Job succeeded.
Details
pull-kubernetes-e2e-gce-100-performance Job succeeded.
Details
pull-kubernetes-e2e-gce-device-plugin-gpu Job succeeded.
Details
pull-kubernetes-e2e-gke Skipped
pull-kubernetes-e2e-kops-aws Job succeeded.
Details
pull-kubernetes-e2e-kubeadm-gce Skipped
pull-kubernetes-integration Job succeeded.
Details
pull-kubernetes-kubemark-e2e-gce-big Job succeeded.
Details
pull-kubernetes-local-e2e Skipped
pull-kubernetes-local-e2e-containerized Skipped
pull-kubernetes-node-e2e Job succeeded.
Details
pull-kubernetes-typecheck Job succeeded.
Details
pull-kubernetes-verify Job succeeded.
Details
tide In merge pool.
Details

@jessfraz jessfraz deleted the jessfraz:only-set-sysctl-if-not-set branch Sep 26, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.