Interview Prep/Kubernetes/Nodes, kubelet and container runtime

`kubectl logs` and `kubectl exec` fail for Pods on one node with `Error from server: Get "https://10.0.1.12:10250/containerLogs/...": dial tcp 10.0.1.12:10250: i/o timeout`.

IntermediateTroubleshootingNodes, kubelet and container runtime
Answer

Likely causes → The API server cannot reach the kubelet port 10250 on that node: security group or firewall rule, node in a subnet without a route from the control plane, or the kubelet is down. The Pods themselves may be perfectly healthy.

Diagnose →

kubectl get node ip-10-0-1-12 -o wide
# From another node or a debug pod on the same network
nc -zv 10.0.1.12 10250
# On the node
sudo ss -lntp | grep 10250

Fix → Open TCP 10250 from the control plane security group / CIDR to the nodes. On EKS, the cluster security group must allow it. While investigating, use crictl logs on the node directly.

Prevent → Manage node security groups in IaC with the required control-plane rules.

All Kubernetes questions

More on Nodes, kubelet and container runtime