Question

Difficulty: EasyAuto Scaling and Elastic Load Balancing (ELB)

A company runs a high-traffic e-commerce platform where a fleet of Amazon EC2 instances in an Auto Scaling group (ASG) serves traffic behind an Application Load Balancer (ALB). During a peak shopping event, several instances experience application-level crashes and stop responding to HTTP requests, but the EC2 status checks show the instances are healthy. The ALB marks the instances as unhealthy and stops sending them traffic, but the Auto Scaling group does not replace them. Which configuration change should the solutions architect make to ensure unhealthy instances are automatically replaced?

  1. Update the Auto Scaling group health check type from EC2 to ELB.Answer
  2. B
    Reconfigure the Application Load Balancer target group health check to query a default port such as port 80, regardless of the application's actual listening port.
  3. C
    Create stateless Network Access Control List (Network ACL) rules to monitor target instance health and terminate unresponsive instances.
  4. D
    Configure an Amazon Route 53 latency-based routing policy with target health evaluation to identify and terminate the failed instances.

Answer

Update the Auto Scaling group health check type from EC2 to ELB.
By default, an Auto Scaling group (ASG) only monitors EC2 status checks. If an application crashes but the operating system and VM remain responsive, the EC2 status checks will pass, and the ASG will not replace the instance. Changing the health check type of the ASG to ELB allows the ASG to use the Application Load Balancer's target group health checks. When the ALB marks an instance as unhealthy, the ASG will automatically terminate and replace it.

Step-by-Step Solution

1
Analyze the health check configuration of the Auto Scaling group (ASG) and the Application Load Balancer (ALB).
The ASG is currently using the default EC2 health check, which only monitors the hypervisor and OS-level status, while the ALB performs application-level HTTP health checks.
This explains why the ASG does not terminate the instances despite the ALB marking them as unhealthy.
2
Change the health check type of the ASG to ELB.
The ASG will now monitor both EC2 status checks and the ALB target group health checks.
To ensure that application-level failures detected by the ALB trigger instance replacement by the ASG.

Key Concept

Auto Scaling Group Health Check Type
Estimated Time:45s
Rate this question