My Amazon EKS is unable to communicate with your Kubernetes cluster API server even though it is active

1

My Amazon EKS is unable to communicate with your Kubernetes cluster API server even though it is active. My API server endpoint access set is Public and private. How do I resolve this?

Enter image description here Cannot use kubectl command Enter image description here AWS console and add-ons have an error when connect to Kubernetes cluster API Enter image description here

Enter image description here

asked 7 months ago965 views
1 Answer
2

Hello,

It is Very regular issue for everyone i will give solution below in easy way: Enter image description here

This is your issue looks likes.

  1. Security Groups: If you're accessing the cluster across a VPC, ensure the control plane security groups allow inbound traffic from the peered VPC on port 443.
  2. Update Your EKS Cluster and Region and check your config file with following commands:

aws eks --region <your region> describe-cluster --name <your cluster name> --query cluster.status

aws eks --region <your region> update-kubeconfig --name <your cluster name>

mv $HOME/.kube/config $HOME/.kube/config.old

kubectl get svc

kubectl get nodes

=> By applying above commands one by one you resolve your issue.

this is the solution for your issue after applying above commands without any error

Enter image description here

Troubleshoot the API server endpoint of an Amazon EKS Cluster: https://docs.aws.amazon.com/eks/latest/userguide/troubleshooting.html

profile picture
EXPERT
answered 7 months ago
profile picture
EXPERT
reviewed 7 months ago
  • I have tried your solution and many other ways but still cannot connect to the API server.

    As far as I know, EKS Control Plane is managed by AWS. How can I get support from AWS regarding this issue?

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions