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

Consolidate sysctl commands for kubelet #43005

Merged

Conversation

cmluciano
Copy link

What this PR does / why we need it:
These commands are important enough to be in the Kubelet itself.
By default, Ubuntu 14.04 and Debian Jessie have these set to 200 and
20000. Without this setting, nodes are limited in the number of
containers that they can start.

Which issue this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged): fixes #26005

Special notes for your reviewer:
I had a difficult time writing tests for this. It is trivial to create a fake sysctl for testing, but the Kubelet does not have any tests for the prior settings.
Release note:

@k8s-ci-robot
Copy link
Contributor

Hi @cmluciano. Thanks for your PR.

I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with @k8s-bot ok to test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

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. I understand the commands that are listed here.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Mar 13, 2017
@k8s-reviewable
Copy link

This change is Reviewable

@k8s-github-robot k8s-github-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. release-note-label-needed labels Mar 13, 2017
Copy link
Contributor

@MHBauer MHBauer left a comment

Choose a reason for hiding this comment

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

I'll let an expert determine the validity of the server.go change, but I'd like the constants to not be totally magic numbers if they actually have a dependency on each other.


VmOvercommitMemoryAlways = 1 // kernel performs no memory over-commit handling
VmPanicOnOOMInvokeOOMKiller = 0 // kernel calls the oom_killer function when OOM occurs

KernelPanicOnOopsAlways = 1 // kernel panics on kernel oops
KernelPanicRebootTimeout = 10 // seconds after a panic for the kernel to reboot

RootMaxKeysSetting = 1000000 // Needed since docker creates a new key per container
RootMaxBytesSetting = 25000000 // allocate 25 bytes per key * number of MaxKeys
Copy link
Contributor

Choose a reason for hiding this comment

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

I like the comment, but if RootMaxBytesSetting depends on RootMaxBytesSetting, actually reference it as 25 * RootMaxBytesSetting.

Copy link
Author

Choose a reason for hiding this comment

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

fixed

@cmluciano
Copy link
Author

@dchen1107 @vishh does this look reasonable to you?

@vishh
Copy link
Contributor

vishh commented Mar 21, 2017

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Mar 21, 2017
@k8s-github-robot k8s-github-robot added the do-not-merge DEPRECATED. Indicates that a PR should not merge. Label can only be manually applied/removed. label Mar 21, 2017
@k8s-github-robot k8s-github-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Mar 22, 2017
@cmluciano
Copy link
Author

Fixed the go-fmt spacing issue. Can I get a retest?

@vishh
Copy link
Contributor

vishh commented Mar 23, 2017

@k8s-bot ok to test

@cmluciano cmluciano force-pushed the cml/consolidatesysctl branch 2 times, most recently from 8c361f1 to c5b2181 Compare March 23, 2017 18:04
@cmluciano
Copy link
Author

ok builds stabilized now after fixing all go fmt problems

@vishh
Copy link
Contributor

vishh commented Mar 23, 2017

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Mar 23, 2017
@vishh
Copy link
Contributor

vishh commented Mar 23, 2017

/release-note-none
/approve

@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. and removed release-note-label-needed labels Mar 23, 2017
@cmluciano
Copy link
Author

@dchen1107 Would you like me to preserve your comment?

@cmluciano
Copy link
Author

cmluciano commented Apr 3, 2017

The new test failure seems to be a random flake. I have not pushed any new changes.

@cmluciano
Copy link
Author

The build logs aren't pointing me to any specific test failures, just that it can't seem to save the junit results

@cmluciano
Copy link
Author

@vishh Can I get a retest?

@cmluciano
Copy link
Author

@k8s-bot test this

These commands are important enough to be in the Kubelet itself.
By default, Ubuntu 14.04 and Debian Jessie have these set to 200 and
20000. Without this setting, nodes are limited in the number of
containers that they can start.
@k8s-github-robot k8s-github-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label May 2, 2017
@cmluciano
Copy link
Author

ok everything looks good to go now

cc @vishh @dchen1107

@vishh
Copy link
Contributor

vishh commented May 4, 2017

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label May 4, 2017
@cmluciano
Copy link
Author

@lavalamp @thockin Since you both are also in the approvers file, can you review this for an approve?

@thockin thockin removed the do-not-merge DEPRECATED. Indicates that a PR should not merge. Label can only be manually applied/removed. label May 24, 2017
@thockin
Copy link
Member

thockin commented May 24, 2017

/approve

@k8s-github-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: cmluciano, thockin, vishh

Needs approval from an approver in each of these OWNERS Files:

You can indicate your approval by writing /approve in a comment
You can cancel your approval by writing /approve cancel in a comment

@k8s-github-robot k8s-github-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label May 24, 2017
@cmluciano
Copy link
Author

kops failure simply timed out, rerunning to see if it is a flake

@k8s-bot pull-kubernetes-e2e-kops-aws test this

@calebamiles calebamiles modified the milestone: v1.7 Jun 2, 2017
@cmluciano
Copy link
Author

@k8s-bot pull-kubernetes-e2e-gce-etcd3 test this

@cmluciano
Copy link
Author

@k8s-bot pull-kubernetes-federation-e2e-gce test this

@k8s-ci-robot
Copy link
Contributor

k8s-ci-robot commented Jun 5, 2017

@cmluciano: The following tests failed, say /retest to rerun them all:

Test name Commit Details Rerun command
Jenkins non-CRI GCE e2e c5b218171e3e7e7a9e613178a1b39ee8a37051ea link @k8s-bot non-cri e2e test this
Jenkins non-CRI GCE Node e2e c5b218171e3e7e7a9e613178a1b39ee8a37051ea link @k8s-bot non-cri node e2e test this
pull-kubernetes-federation-e2e-gce bafabcb link @k8s-bot pull-kubernetes-federation-e2e-gce test this

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

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. I understand the commands that are listed here.

@cmluciano
Copy link
Author

@justinsb Do you know if kops is doing anything special with the sysctls? I'm not sure if I also need to change something in kops.

@cmluciano
Copy link
Author

/retest

@k8s-github-robot
Copy link

Automatic merge from submit-queue (batch tested with PRs 43005, 46660, 46385, 46991, 47103)

@k8s-github-robot k8s-github-robot merged commit 69342bd into kubernetes:master Jun 7, 2017
@cmluciano cmluciano deleted the cml/consolidatesysctl branch June 7, 2017 21:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note-none Denotes a PR that doesn't merit a release note. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cleanup system configuration at node
9 participants