You have an application running on EC2. You want to automatically increase or decrease the number of instances in response to changes in demand, and also automatically replace unhealthy instances. Which service is the most appropriate?

1 / 1
Select an answer
CorrectB

Explanation

Choosing a service that follows demand and automatically replaces instances.

  • 1in response to changes in demandAutomatically adjust capacity to follow load
  • 2automatically increase or decrease the number of instancesAutomate scale-out/in
  • 3automatically replace unhealthy instancesSelf-healing via health checks is required
AIncorrect

Amazon CloudFront

CloudFront is a CDN service that caches content at edge locations for low-latency delivery.

It does not scale the number of EC2 instances or replace unhealthy instances, so it is incorrect.

BCorrect

Amazon EC2 Auto Scaling

Correct. EC2 Auto Scaling automatically increases or decreases the number of instances (scale out/in) in response to demand, and automatically terminates and replaces instances detected as unhealthy by health checks. It provides both demand-following and automatic recovery from instance failures.

CIncorrect

Amazon S3

S3 is an object storage service used to store and serve files.

It does not manage or replace the number of EC2 instances, so it is incorrect.

DIncorrect

AWS IAM

IAM is a service that manages access permissions.

It is not involved in scaling the number of instances or replacing failed instances, so it is incorrect.

Key Takeaway

'Automatic scaling of the instance count' and 'replacing unhealthy instances' point to EC2 Auto Scaling. Combined with a load balancer (ELB), it is the classic pattern for 'demand-following + high availability'.