flannel
flannel copied to clipboard
Pods cannot start, kube-flannet-ds pod shows the message with "OCI runtime create failed"
After deploying flannel in fresh k8s cluster one of the pods constantly fails with the message
OCI runtime create failed: container_linux.go:367: starting container process caused: process_linux.go:495: container init caused: process_linux.go:458: setting cgroup config for procHooks process caused: open /sys/fs/cgroup/kubepods.slice/kubepods-burstable.slice/kubepods-burstable-pod7cd213f2_19f2_44bb_90e7_abdb097d5ea4.slice/docker-24a247c30100464900b21fe5e06038fb9743b43a382a9b604e4cd18162854d4e.scope/memory.swap.max: no such file or directory: unknown
Expected Behavior
-
kube-flannel-ds
pods are up and running - pods can be started
Current Behavior
- Currently one of the
kube-flannel-ds
pods constantly fails with the message mentioned above. - no pods can be started. The message in pods log is
Failed to create pod sandbox: rpc error: code = Unknown desc = failed to set up sandbox container "cdecf1c40e8cba2d95663ae69bd6e7def100725d7487a0ef361ee1c64838df43" network for pod "nginx-deployment-585449566-9l92m": networkPlugin cni failed to set up pod "nginx-deployment-585449566-9l92m_default" network: open /run/flannel/subnet.env: no such file or directory
Steps to Reproduce (for bugs)
- Install k8s cluster by kubeadm (master node only)
- install flannel by
kubectl apply -f https://raw.githubusercontent.com/coreos/flannel/master/Documentation/kube-flannel.yml
- see the problem described above
Environment
- Flannel version: v0.14.0
- Kubernetes version (if used): v1.21.1
- Operating System and version: Ubuntu Server 20.04.2 LTS
Any suggestions/ recommendations how to address it?
Thank you
maybe you need to configure those in the Kernel settings: https://docs.docker.com/engine/install/linux-postinstall/#your-kernel-does-not-support-cgroup-swap-limit-capabilities
I configured it. My /etc/default/grub
contains
GRUB_CMDLINE_LINUX_DEFAULT="maybe-ubiquity systemd.unified_cgroup_hierarchy=1 cgroup_enable=memory swapaccount=1"
and I see that for another processes in /sys/fs/cgroup
Another detail that might be relevant, I use containerd
as CRI which is configured to use systemd
as cgroup manager.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.