Interview Prep/Kubernetes/EKS-specific issues

After someone edited `aws-auth`, all nodes went `NotReady` and nobody except the cluster creator can use kubectl.

AdvancedTroubleshootingEKS-specific issues
Answer

Likely causes → The ConfigMap was broken: invalid YAML, the node role mapping (system:bootstrappers, system:nodes) removed or overwritten by a tool that rewrote the whole map. Nodes can no longer authenticate.

Diagnose →

kubectl get cm aws-auth -n kube-system -o yaml      # as the cluster creator or via access entry admin
kubectl get nodes

Fix → Restore the node role mapping:

mapRoles: |
  - rolearn: arn:aws:iam::111122223333:role/eks-node-role
    username: system:node:{{EC2PrivateDNSName}}
    groups: [system:bootstrappers, system:nodes]

If no one can authenticate, use the cluster creator identity or create an access entry through the EKS API (works independently of aws-auth when the auth mode is API_AND_CONFIG_MAP).

Prevent → Migrate to access entries; managed node groups get their access entries automatically. Never edit aws-auth by hand.

All Kubernetes questions

More on EKS-specific issues