mirror of https://github.com/k3s-io/k3s
![]() Automatic merge from submit-queue (batch tested with PRs 64503, 64903, 64643, 64987). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. Use unix.EpollWait to determine when memcg events are available to be Read **What this PR does / why we need it**: This fixes a file descriptor leak introduced in https://github.com/kubernetes/kubernetes/pull/60531 when the `--experimental-kernel-memcg-notification` kubelet flag is enabled. The root of the issue is that `unix.Read` blocks indefinitely when reading from an event file descriptor and there is nothing to read. Since we refresh the memcg notifications, these reads accumulate until the memcg threshold is crossed, at which time all reads complete. However, if the node never comes under memory pressure, the node can run out of file descriptors. This PR changes the eviction manager to use `unix.EpollWait` to wait, with a 10 second timeout, for events to be available on the eventfd. We only read from the eventfd when there is an event available to be read, preventing an accumulation of `unix.Read` threads, and allowing the event file descriptors to be reclaimed by the kernel. This PR also breaks the creation, and updating of the memcg threshold into separate portions, and performs creation before starting the periodic synchronize calls. It also moves the logic of configuring memory thresholds into memory_threshold_notifier into a separate file. This also reverts https://github.com/kubernetes/kubernetes/pull/64582, as the underlying leak that caused us to disable it for testing is fixed here. Fixes #62808 **Release note**: ```release-note NONE ``` /sig node /kind bug /priority critical-urgent |
||
---|---|---|
.. | ||
addons | ||
centos | ||
gce | ||
images | ||
juju | ||
kubemark | ||
kubernetes-anywhere | ||
local | ||
log-dump | ||
pre-existing | ||
skeleton | ||
BUILD | ||
OWNERS | ||
README.md | ||
clientbin.sh | ||
common.sh | ||
get-kube-binaries.sh | ||
get-kube-local.sh | ||
get-kube.sh | ||
kube-down.sh | ||
kube-up.sh | ||
kube-util.sh | ||
kubeadm.sh | ||
kubectl.sh | ||
restore-from-backup.sh | ||
test-e2e.sh | ||
test-network.sh | ||
test-smoke.sh | ||
update-storage-objects.sh | ||
validate-cluster.sh |
README.md
Cluster Configuration
Deprecation Notice: This directory has entered maintenance mode and will not be accepting new providers. Please submit new automation deployments to kube-deploy. Deployments in this directory will continue to be maintained and supported at their current level of support.
The scripts and data in this directory automate creation and configuration of a Kubernetes cluster, including networking, DNS, nodes, and master components.
See the getting-started guides for examples of how to use the scripts.
cloudprovider/config-default.sh
contains a set of tweakable definitions/parameters for the cluster.
The heavy lifting of configuring the VMs is done by SaltStack.