1
votes

I created an ECS cluster, that contains two EC2 instances of t3.nano type. Now I need to create another one within the same account and the same region, but with different instance types.

The problem is that the cluster is created, but EC2 instances are not. I'm creating the cluster via AWS ECS console. Instances of the first cluster were successfully created via ECS console too. I'm launching them in public subnets, so that ECS agent could reach the cluster, but it's not that EC2 instances can't register within the cluster, it's that they are not even created, even though the very cluster is successfully created.

What am I doing wrong?

2

2 Answers

0
votes

This sounds like you have chosen the wrong cluster template. If you choose Networking Only (Fargate) template, there will be no instance created since Fargate is serverless solution where you don't manage its underlying EC2 container instances.

Another thing is that you might have reached the default soft limit on the number of instances that you can run within a single region, which is 20, but you should see an error telling you that. Or it may be that there is not enough on-demand EC2 capacity in AZs where you are launching your cluster but this is highly unlikely and again, there should be some error informing you about that fact.

3
votes

If you're experiencing this problem, have a look on AutoScaling group in EC2 console, that gets created when you launch a cluster. Turns out mine was showing "Launching a new EC2 instance. Status Reason: Your quota allows for 0 more running instance(s). You requested at least 1. Launching EC2 instance failed.".

If you see this - the only solution seems to be is to contact AWS support.