Comment 0 for bug 1968830

Revision history for this message
DingGGu (dinggggu) wrote :

https://cloud-images.ubuntu.com/aws-eks/

Since Ubuntu EKS 1.22 AMI, containerd has become the default container runtime.

When the node receives DiskPressure,kubelet gc the unused image. I faced pause container image has been removed from during operation. After the pause container is deleted, the node can no longer create pods. (related with containerd does not support ecr native image pull)

kubelet has a pod-infra-container-image flag, which prevents gc to suspend container images.

Edit the bootstrap.sh file so that the pod-infra-container-image flag is set in all container runtimes.

I am using bootstrap.sh by modifying it.

mv /etc/eks/bootstrap.sh /etc/eks/bootstrap.sh.orig
sed "s,container-runtime-endpoint=unix:///run/containerd/containerd.sock,container-runtime-endpoint=unix:///run/containerd/containerd.sock pod-infra-container-image=" \$PAUSE_CONTAINER",g" < /etc/eks/bootstrap.sh.orig > /etc/eks/bootstrap.sh
chmod +x /etc/eks/bootstrap.sh