I am doing getting started with AWS-EKS demo on my machine. I created a EKS cluster, Worker nodes and then attached those nodes to the Cluster and deployed nginx service over the nodes. In first attempt, I could do this demo successful, and I was able to access the Load balancer url, having nginx service deployed on it. Now while playing with the instance, both of my nodes say node1 and node2 got deleted with below commands
kubectl delete node <node-name>
node "ip-***-***-***-**.ap-south-1.compute.internal" deleted
To recover this i spent more time, i found that the Load balancer URL is ACTIVE, the two respective EC2 instances (or worker nodes) are running fine. However, below command gives this result
PS C:\k8s> kubectl get nodes
No resources found.
PS C:\k8s>
I tried to replicate step#3 from getting started guide But could end up only in recreating the same worker nodes
When i try to create a pods again on the same EC2 instances or worker node, it says STATUS is pending for pods
PS C:\k8s> kubectl create -f .\aws-pod-nginx.yaml
deployment.apps/nginx created
PS C:\k8s> kubectl get pods
NAME READY STATUS RESTARTS AGE
nginx-76b782ee75-n6nwv 0/1 Pending 0 38s
nginx-76b78dee75-rcf6d 0/1 Pending 0 38s
PS C:\k8s> kubectl get pods
when i describe the pod error is as below:
Events:
Type Reason Age From Message
---- ------ ---- ---- -------
Warning FailedScheduling 52s (x5 over 4m11s) default-scheduler no nodes available to schedule pods
I have my two EC2 instances (or worker nodes) running, I tried to attach those to ELB url manually, but the service status is 'OutOfService' for those EC2 instances
I would like to get result of the below command, having working nodes, which can be accessed from the ELB, but the result of below command 'no resources found':
kubectl get nodes