Question

Difficulty: Very hardImplementing Auto Scaling and Fault Tolerance

A gaming company hosts a multiplayer matchmaking service on AWS. The application's compute tier is deployed in private subnets across three Availability Zones (useast1aus-east-1a, useast1bus-east-1b, and useast1cus-east-1c) within an Auto Scaling group (ASG) behind an Application Load Balancer (ALB). Outbound requests to external third-party game servers are routed through a single NAT Gateway located in useast1aus-east-1a.

During a daily scheduled global tournament, player traffic surges instantaneously. The following issues are observed:
1. Outbound traffic to the external game servers fails completely if there is an outage in useast1aus-east-1a, disabling matchmaking for players in useast1bus-east-1b and useast1cus-east-1c.
2. The ASG scale-out policy (based on CPU utilization) triggers immediately during the traffic surge. However, because new instances require 88 minutes (480480 seconds) to download configuration files, install dependencies, and bootstrap the application, the ASG continues to launch unnecessary additional instances every few minutes before the previously launched instances can start processing traffic. This behavior leads to significant over-provisioning and high compute costs.

Which two actions should the solutions architect take to resolve these issues while maintaining high availability and minimizing cost?

  1. Deploy a NAT Gateway in the public subnet of each Availability Zone, and update the route tables of the private subnets to route outbound traffic through the NAT Gateway located in their respective Availability Zone.Answer
  2. Configure the step scaling policy's warmup period and the Auto Scaling group's default cooldown period to at least 500 seconds, ensuring that no new scaling activities are triggered before the running instances complete their bootstrapping.Answer
  3. C
    Deploy a secondary NAT Gateway in the public subnet of useast1bus-east-1b, and configure a Route 53 active-passive failover policy to dynamically update the VPC route tables if the primary NAT Gateway in useast1aus-east-1a fails.
  4. D
    Modify the scaling policy to use target tracking on CPU utilization with the instance warm-up set to 120 seconds, allowing the Auto Scaling group to aggressively launch instances to absorb the flash traffic.
  5. E
    Request AWS Support to pre-warm the Application Load Balancer, and configure the target group deregistration delay to 480 seconds to allow the instances to receive traffic during their bootstrapping phase.

Answer

Deploy a NAT Gateway in the public subnet of each Availability Zone and update private subnet route tables, and configure the step scaling policy's warmup period and the Auto Scaling group's default cooldown period to at least 500 seconds.
To ensure high availability and fault tolerance for outbound internet traffic, a NAT Gateway must be deployed in the public subnet of each Availability Zone, and the private subnet route tables must be updated to route traffic through their local NAT Gateway. This eliminates the single point of failure and cross-AZ dependency of the single NAT Gateway. To resolve the over-provisioning issue caused by the 8-minute bootstrapping time, the scaling policy's warmup period and the default cooldown period must be increased to a duration longer than the bootstrapping time (e.g., 500 seconds). This prevents the Auto Scaling group from launching additional instances before the previously launched instances have finished bootstrapping and begun reporting metrics.

Step-by-Step Solution

1
Analyze the outbound traffic path during an Availability Zone outage.
The single NAT Gateway in the first Availability Zone represents a single point of failure for all three Availability Zones.
Outbound communication with external game servers is critical for matchmaking across all zones.
2
Determine the correct configuration to establish high availability for outbound traffic.
A NAT Gateway must be deployed in each of the three Availability Zones, with respective private subnet route tables updated to route traffic locally.
This removes the cross-AZ dependency and ensures that an outage in one zone does not affect outbound traffic in the remaining zones.
3
Evaluate the relationship between instance bootstrapping duration and Auto Scaling group scaling activity.
The 8-minute bootstrapping time is significantly longer than the time the ASG waits before initiating another scaling evaluation.
When the ASG launches an instance, if the warm-up and cooldown periods are shorter than 8 minutes, the ASG will evaluate metrics before the instance is ready to take load, resulting in over-provisioning.
4
Formulate the correct Auto Scaling group policy adjustments.
Set both the step scaling policy's warm-up period and the default cooldown period to at least 500 seconds (greater than 480 seconds).
This forces the ASG to pause scaling evaluations until the newly launched instances are ready and contributing to CPU utilization metrics, preventing unnecessary scale-out.

Key Concept

To prevent scale-out over-provisioning when EC2 instances have long bootstrap times, the Auto Scaling group's cooldown and scaling policy warm-up periods must be configured to be longer than the bootstrap duration. Additionally, NAT Gateways must be deployed in each Availability Zone to avoid cross-AZ failures and single points of failure for outbound traffic.
Estimated Time:4m 0s
Rate this question