EKS Cluster Create Failed

0

I am trying to create an eks cluster using the eksctl command. However, an error occurs as below:

AWS::EKS::Cluster/ControlPlane: CREATE_FAILED – "Resource handler returned message: "Duplicate key <<cluster_name>/ControlPlane"

If you try to delete it using cloudformation, it fails because of ControlPlane.

Currently, there is no EKS Cluster.

  • Check your ControlPlane tags in the CloudFormation Template. One is call "Name" and is created automatically. If you already put one that will fail.

  • AWS-User-4425126 6 days ago Check your ControlPlane tags in the CloudFormation Template. One is call "Name" and is created automatically. If you already put one that will fail.

    You're right Name is hard coding in cluster yaml file This problem is solved

    Thank you [AWS-User-4425126]

질문됨 2년 전1204회 조회
2개 답변
1
수락된 답변

You can try to create a EKS cluster with other cluster name. I think it will work.

And back to the question, I believe you had the EKS same cluster name had created. If you can't delete it from cloudformation, Highly recommend to check the detail about the cloudformations log to get more info. Sometimes, you can't delete the cloudformation cause of you attached some IAM policy to IAM Role which created by eksctl.

ZenoRen
답변함 2년 전
  • Maby when deleting the cluster using cloudformation, it seems to have been deleted by retained Control Plane resource. So cloudformation stack deleted.

    I retry different cluster name, but same error returned. However, it is created EKS Cluster with AWS Console Management.

    As your guess, this seems to be caused by modifying the IAM role. Currently, I posted an article in Feedback on the Cloudformation page.

    Thanks for posting the answer.

1

I have a problem too, But I can solve this issue.

In my example, to install EKS I use eksctl and configure file. like this.

apiVersion: eksctl.io/v1alpha5
kind: ClusterConfig

metadata:
  name: cluster-name
  region: ap-southeast-1
  version: "1.21"
  tags:
    Createby: xxxxx
    Environment: env-name
    Name: cluster-name
    Owner: owner-name
    Service: service-name
    System: system-name

in my configuration in the metadata section, There is a tag name that in earlier versions of eksctl has no problem, but in eksctl v0.82.0 there is a problem. When I checked in cloudformation template, I found a duplicate Tag Name like this.

        "Tags": [
          {
            "Key": "Environment",
            "Value": "env-name"
          },
          {
            "Key": "Owner",
            "Value": "owner-name"
          },
          {
            "Key": "Service",
            "Value": "service-name"
          },
          {
            "Key": "System",
            "Value": "system-name"
          },
          {
            "Key": "Createby",
            "Value": "xxxxx"
          },
          {
            "Key": "Name",
            "Value": "cluster-name"
          },
          {
            "Key": "Name",
            "Value": {
              "Fn::Sub": "${AWS::StackName}/ControlPlane"
            }
          }
        ],

When I tried to remove the tag name from config files and try again, it's work fine.

apiVersion: eksctl.io/v1alpha5
kind: ClusterConfig

metadata:
  name: cluster-name
  region: ap-southeast-1
  version: "1.21"
  tags:
    Createby: xxxxx
    Environment: env-name
    Owner: owner-name
    Service: service-name
    System: system-name
zendz
답변함 2년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠