AWS EKS Kubernetes pods taking a lot of time to get READY

Viewed 240

Github repo: https://github.com/oussamabouchikhi/udagram-microservices

After I configured the kubectl with the AWS EKS cluster, I deployed the services using these commands

kubectl apply -f env-configmap.yaml
kubectl apply -f env-secret.yaml
kubectl apply -f aws-secret.yaml
# this is repeated for all services 
kubectl apply -f svcname-deploymant.yaml
kubectl apply -f svcname-service.yaml

enter image description here

But the pods took hours and still in PENDING state, and when I run the command kubectl describe pod <POD_NAME> I get the follwing info

reverseproxy-667b78569b-2c6hv pod: https://pastebin.com/3xF04SEx
udagram-api-feed-856bbc5c45-jcgtk pod: https://pastebin.com/5UqB79tU
udagram-api-users-6fbd5cbf4f-qbmdd pod: https://pastebin.com/Hiqe1LAM

1 Answers

From your kubectl describe pod <podname>

Warning FailedScheduling 2m19s (x136 over 158m) default-scheduler 0/2 nodes are available: 2 Too many pods.

When you see this, it means that your nodes in AWS EKS is full.

To solve this, you need to add more (or bigger) nodes.

You can also investigate your nodes, e.g. list your nodes with:

kubectl get nodes

and investigate a specific node (check how many pods it has capacity for - and how many pods that runs on the node) with:

kubectl describe node <node-name>
Related