Q7 — AWS SAA-C03 Ch.1
Question 7 of 65 | ← Chapter 1
Q7. An application runs on Amazon EC2 instances across multiple Availability Zones. The instances run in an Amazon EC2 Auto Scaling group behind an Application Load Balancer. The application performs best when the CPU utilization of the EC2 instances is at or near 40%. What should a solutions architect do to maintain the desired performance across all instances m the group?
- A. Use a simple scaling policy to dynamically scale the Auto Scaling group
- B. Use a target tracking policy to dynamically scale the Auto Scaling group ✓
- C. Use an AWS Lambda function to update the desired Auto Scaling group capacity
- D. Use scheduled scaling actions to scale up and scale down the Auto Scaling group
Correct Answer: B. Use a target tracking policy to dynamically scale the Auto Scaling group
Explanation
To maintain the desired performance across all instances in the Auto Scaling group, where the optimal CPU utilization is at or near 40%, the solutions architect should choose a scaling policy that can dynamically adjust the capacity of the group based on the actual CPU utilization.Let's evaluate the options:A. Use a simple scaling policy to dynamically scale the Auto Scaling group: A simple scaling policy allows for defining thresholds and corresponding scaling actions (scale up or scale down) based on a single metric. However, it does not inherently track a target value like 40% CPU utilization. It would require manual adjustments to the thresholds and might not be as responsive or accurate in maintaining the desired CPU utilization.B. Use a target tracking policy to dynamically scale the Auto Scaling group: A target tracking policy automatically adjusts the capacity of the Auto Scaling group to maintain a target value for a specific metric. In this case, the target metric would be CPU utilization, and the target value would be 40%. This policy continuously adjusts the capacity to keep the CPU utilization close to the target value, which is exactly what's needed to maintain the desired performance.C. Use an AWS Lambda function to update the desired Auto Scaling group capacity: While a Lambda function could be used to update the desired capacity of the Auto Scaling group based on some custom logic, it would require additional setup and maintenance compared to using built-in scaling policies. Moreover, Lambda functions would need to poll the CPU utilization metrics periodically and might not be as responsive or cost-effective as using a target tracking policy.D. Use scheduled scaling actions to scale up and scale down the Auto Scaling group: Scheduled scaling actions are based on time, not on the actual load or CPU utilization of the instances. They are useful for predictable changes in load but are not suitable for maintaining a specific CPU utilization target.Therefore, the best option to maintain the desired performance across all instances in the Auto Scaling group is:B. Use a target tracking policy to dynamically scale the Auto Scaling group.