-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
CrashLoopBackOff Error in kube-proxy with kernel versions 5.12.2.arch1-1 and 5.10.35-1-lts #2240
Comments
I'm getting same results with Quick workaround if a cluster is needed fast: Manually set the parameter with |
This workaround works because kubernetes/kubernetes#44919 (kube-proxy will not try to write if the existing value is high enough, despite the logs suggesting that it set it). We could explicitly configure the max to 0 or some very small value in kind's kube-proxy possibly, but I think you would still want to increase the actual value for things to work well. In normal usage kind is not setting this and relying on the host kernel to have a suitable value, as we've encountered cc @aojea |
@hyutota @BenTheElder I don't think this is an Arch Linux-only issue. According to the changleog of Linux 5.12.2, this commit (torvalds/linux@671c54e) has changed the behaviour of netfilter conntrack. I believe this is the commit that has caused this issue after upgrading to Linux 5.12.2. |
wow, so it seems that we can't set nf_conntrack_max in kind, it will fail for kernels +5.12.2 🤔 the good thing is that jthe fix seems simple, is just enable by default kind/pkg/cluster/internal/kubeadm/config.go Lines 414 to 420 in b6bc112
|
I can confirm that #2241 fixes the issue for me on kernel |
thanks all, #2241 should be in shortly, and since we're quite overdue for a release it should be released soon. |
Hello, thanks for sharing. Can you elaborate further what todo exactly? I deleted all cluster configs. (.minikube, .kube)
I assume there is no other solution atm? I am using Minikube with Kernel 5.10.36-2-MANJARO. |
@muellerti Could you try the following steps and see if it works?
|
Man! Thanks! That worked, I should have thought of that myself. |
It contains a fix for kubernetes-sigs/kind#2240 We've hit when running GitHub actions actions/runner-images#3673
- use a ubuntu 20.04 - set nf_conntrack_max to avoid CrashLoopBackOff for kube proxy (see kubernetes-sigs/kind#2240 (comment)) - print cluster info as soon as KinD is up Signed-off-by: Mattia Mazzucato <[email protected]>
- use ubuntu 20.04 - set nf_conntrack_max to avoid CrashLoopBackOff for kube proxy (see kubernetes-sigs/kind#2240 (comment)) - print cluster info as soon as KinD is up Signed-off-by: Mattia Mazzucato <[email protected]>
- use ubuntu 20.04 - set nf_conntrack_max to avoid CrashLoopBackOff for kube proxy (see kubernetes-sigs/kind#2240 (comment)) - print cluster info as soon as KinD is up Signed-off-by: Mattia Mazzucato <[email protected]>
- use a ubuntu 20.04 - set nf_conntrack_max to avoid CrashLoopBackOff for kube proxy (see kubernetes-sigs/kind#2240 (comment)) - print cluster info as soon as KinD is up - use kind-action v1.4.0 - bump KinD to v0.10.0 - use kube-tools v1.5.0 Signed-off-by: Mattia Mazzucato <[email protected]>
- use ubuntu 20.04 - set nf_conntrack_max to avoid CrashLoopBackOff for kube proxy (see kubernetes-sigs/kind#2240 (comment)) - print cluster info as soon as KinD is up - use kind-action v1.4.0 - bump KinD to v0.10.0 - use kube-tools v1.5.0 Signed-off-by: Mattia Mazzucato <[email protected]>
- use ubuntu 20.04 - set nf_conntrack_max to avoid CrashLoopBackOff for kube proxy (see kubernetes-sigs/kind#2240 (comment)) - print cluster info as soon as KinD is up - use kind-action v1.4.0 - bump KinD to v0.10.0 Signed-off-by: Mattia Mazzucato <[email protected]>
For kube-proxy not becoming ready, like this: semaphore@semaphore-vm:~$ kubectl logs kube-proxy-42v55 -n kube-system I0727 19:55:26.230888 1 node.go:135] Successfully retrieved node IP: 172.17.0.2 I0727 19:55:26.230923 1 server_others.go:172] Using ipvs Proxier. I0727 19:55:26.230930 1 server_others.go:174] creating dualStackProxier for ipvs. W0727 19:55:26.232364 1 proxier.go:420] IPVS scheduler not specified, use rr by default W0727 19:55:26.232522 1 proxier.go:420] IPVS scheduler not specified, use rr by default W0727 19:55:26.232538 1 ipset.go:107] ipset name truncated; [KUBE-6-LOAD-BALANCER-SOURCE-CIDR] -> [KUBE-6-LOAD-BALANCER-SOURCE-CID] W0727 19:55:26.232546 1 ipset.go:107] ipset name truncated; [KUBE-6-NODE-PORT-LOCAL-SCTP-HASH] -> [KUBE-6-NODE-PORT-LOCAL-SCTP-HAS] I0727 19:55:26.232648 1 server.go:571] Version: v1.17.0 I0727 19:55:26.232963 1 conntrack.go:100] Set sysctl 'net/netfilter/nf_conntrack_max' to 131072 F0727 19:55:26.232982 1 server.go:485] open /proc/sys/net/netfilter/nf_conntrack_max: permission denied See kubernetes-sigs/kind#2240 and kubernetes-sigs/kind#2241.
Resolves an crash issue on linux machines noted here: kubernetes-sigs/kind#2240 Co-authored-by: Ken Sipe <[email protected]>
i'm using ubuntu operating system ,add the line to sysctl config file
and let the parameter work imediately and restart minikube
|
This addresses #18 kubernetes-sigs/kind#2240 Signed-off-by: Kurt Garloff <[email protected]>
This addresses #18 kubernetes-sigs/kind#2240 Signed-off-by: Kurt Garloff <[email protected]>
* Inject sysctl changing nf_conntrack_max to 131072. This addresses #18 kubernetes-sigs/kind#2240 * Need to load nf_conntrack kmod for the sysctl setting. * Add nf_conntrack to modules-load.d to ensure sysctl works. This is required to be reboot safe. Signed-off-by: Kurt Garloff <[email protected]>
Hi All, With the latest Kind binary and Kubernetes images I am no longer seeing this issue. Bumping the max number to the same value we observed in the Kube-proxy logs, solved the issue and we are able to create the cluster fine. Kind version: 0.11.1 I'm wondering if there is a long term solution that avoids the need of this? Thanks in advance! |
You should not see this issue with any number of nodes in the latest release. Can you confirm that this is minimally reproducible with the latest release and file a new issue if not? |
Thanks for your response Ben. On further investigation, the old Kind executable is taking precedence in the path on that particular environment. Removing it out showed no issues, cluster is up and running as expected. |
We also update the base image version to v1.21.1. kubernetes-sigs/kind#2240 Signed-off-by: Hajime Tazaki <[email protected]>
We also update the base image version to v1.21.1. kubernetes-sigs/kind#2240 Signed-off-by: Hajime Tazaki <[email protected]>
We also update the base image version to v1.21.1. kubernetes-sigs/kind#2240 Signed-off-by: Hajime Tazaki <[email protected]>
how do i fix this issue on mac os? |
change maxPerCore to 0 in configMap of kube-proxy to leave the limit as-is and ignore conntrack-min |
kubernetes-sigs/kind#2240 Kind v0.11.1 is going to fix this issue, but upgrading breaks the bank-vaults which takes a lot to upgrade to postponed. Instead I added a post-kind-create-clusters step to fix the issue for macOS context where a ConfigMap change is enough.
kubernetes-sigs/kind#2240 Kind v0.11.1 is going to fix this issue, but upgrading breaks the bank-vaults which takes a lot to upgrade to postponed. Instead I added a post-kind-create-clusters step to fix the issue for macOS context where a ConfigMap change is enough.
@yharish991 run |
As mentioned in kubernetes-sigs/kind#2240 there was a change in the linux kernel after 5.12.2 that makes nf_conntrack_max read-only in non-init network namespaces, which prevents kind's kube-proxy container from working correctly on kind versions older than v0.11.1. This PS updates the script to download v0.11.1 to avoid this issue. If older versions are needed, the kind url can be set as an environment variable as shown in airshipctl/tools/deployment.provider_common/01_install_kind.sh. Relates-To: #583 Change-Id: Icd9e649fa112e9f6307034ec69dde5d4a7ad613d
Kind was failing to come up silently likely due to kubernetes-sigs/kind#2240 Bumping versions appears to have fixed the issue.
What happened: After creating the cluster with
kind create cluster
, the kube-proxy pod have a CrashLoopBackOff Error. This happens at the kernel versions 5.12.2.arch1-1 and 5.10.35-1-lts. With kernel versions 5.12.1.arch1-1 and 5.10.34-1-lts I didn't had the issue.What you expected to happen: All pods in the cluster should start without problems.
How to reproduce it (as minimally and precisely as possible): On a Arch Linux install with kernel version 5.12.2.arch1-1 or 5.10.35-1-lts with docker installed download the latest version of kind and run
kind create cluster
.Anything else we need to know?:
Enviroment:
kind version: (use
kind version
): Tested both:Kubernetes version: (use
kubectl version
):docker info
):/etc/os-release
):The text was updated successfully, but these errors were encountered: