Question

Difficulty: Very hardOptimizing Resource Costs and Sizing

An enterprise manages a multi-account AWS environment under a single organization in AWS Organizations with consolidated billing. The architecture includes the following workloads running 24/7:

WorkloadCurrent ConfigurationCloudWatch CPU UtilizationCloudWatch Memory Utilization
ECS Fargate Tasks (Account A)3030 tasks across 33 AZs; 22 vCPU, 8 GB8\text{ GB} RAM per taskAverage: 28%28\%, Peak: 48%48\%Average: 35%35\%, Peak: 55%55\%
EC2 Instances (Account B)1010 instances of `m6i.xlarge` (44 vCPU, 16 GB16\text{ GB} RAM) in an ASG across 22 AZsAverage: 22%22\%, Peak: 40%40\%Average: 30%30\%, Peak: 45%45\%
AWS Lambda (Account A)20 million20\text{ million} requests/month; 1024 MB1024\text{ MB} memory, 800 ms800\text{ ms} avg durationN/AN/A

Outbound traffic to the internet from the Fargate tasks in Account A is routed through a dedicated NAT Gateway in each of the 33 Availability Zones. The company requires maximum cost optimization across all compute and network resources while maintaining high availability with no single points of failure, and ensuring that no workloads experience performance degradation or out-of-memory errors under peak loads.

Which of the following strategies should a Solutions Architect recommend to achieve the most cost-effective architecture?

  1. Right-size the ECS Fargate tasks in Account A to 11 vCPU and 5 GB5\text{ GB} RAM. Right-size the EC2 instances in Account B to `m6i.large`. Maintain the 33 NAT Gateways in Account A. Purchase a single Compute Savings Plan at the AWS Organizations management account level.Answer
  2. B
    Right-size the ECS Fargate tasks in Account A to 11 vCPU and 5 GB5\text{ GB} RAM. Right-size the EC2 instances in Account B to `m6i.large`. Decommission two NAT Gateways in Account A and route all outbound traffic through a single NAT Gateway in one Availability Zone. Purchase a single Compute Savings Plan at the AWS Organizations management account level.
  3. C
    Right-size the ECS Fargate tasks in Account A to 11 vCPU and 5 GB5\text{ GB} RAM. Right-size the EC2 instances in Account B to `m6i.large`. Maintain the 33 NAT Gateways in Account A. Purchase an EC2 Instance Savings Plan for the `m6i` family at the AWS Organizations management account level to cover the EC2 instances, and purchase a Compute Savings Plan in member Account A to cover the Fargate and Lambda workloads.
  4. D
    Right-size the ECS Fargate tasks in Account A to 11 vCPU and 5 GB5\text{ GB} RAM. Right-size the EC2 instances in Account B to `m6i.large`. Share the NAT Gateways in Account B's VPC with Account A's VPC using AWS Resource Access Manager (RAM) to eliminate NAT Gateway hourly charges in Account A. Purchase a single Compute Savings Plan at the AWS Organizations management account level.

Answer

Right-size the ECS Fargate tasks in Account A to 11 vCPU and 5 GB5\text{ GB} RAM. Right-size the EC2 instances in Account B to `m6i.large`. Maintain the 33 NAT Gateways in Account A. Purchase a single Compute Savings Plan at the AWS Organizations management account level.
The correct strategy combines precise right-sizing with organizational-level financial planning. Sizing the Fargate tasks to 1 vCPU1\text{ vCPU} and 5 GB5\text{ GB} RAM meets the peak memory requirement of 4.4 GB4.4\text{ GB}, preventing OOM crashes, while `m6i.large` matches the 7.2 GB7.2\text{ GB} peak memory of the EC2 instances. Buying a Compute Savings Plan at the AWS Organizations management level covers Fargate, Lambda, and EC2 workloads across all accounts and ensures flexibility. Keeping 33 NAT Gateways ensures high availability without cross-AZ data transfer charges.

Step-by-Step Solution

1
Calculate peak resource requirements for the ECS Fargate tasks in Account A.
Peak CPU is 48%48\% of 2 vCPU=0.96 vCPU2\text{ vCPU} = 0.96\text{ vCPU}. Peak memory is 55%55\% of 8 GB=4.4 GB8\text{ GB} = 4.4\text{ GB}.
Sizing must support peak utilization to prevent performance degradation or out-of-memory (OOM) crashes. 1 vCPU1\text{ vCPU} and 5 GB5\text{ GB} RAM is the smallest standard Fargate configuration that safely covers both peak CPU and memory. Sizing to 4 GB4\text{ GB} RAM would result in OOM errors.
2
Calculate peak resource requirements for the EC2 instances in Account B.
Peak CPU is 40%40\% of 4 vCPU=1.6 vCPU4\text{ vCPU} = 1.6\text{ vCPU}. Peak memory is 45%45\% of 16 GB=7.2 GB16\text{ GB} = 7.2\text{ GB}.
Sizing must support peak utilization. The `m6i.large` instance type offers 2 vCPU2\text{ vCPU} and 8 GB8\text{ GB} RAM, which satisfies these peak requirements cost-effectively.
3
Evaluate the networking configuration to maintain high availability and prevent single points of failure.
Retain 33 NAT Gateways in Account A across 33 Availability Zones.
Deleting NAT Gateways to route cross-AZ introduces a single point of failure and cross-AZ data transfer fees. NAT Gateways cannot be shared directly across accounts or VPCs using AWS Resource Access Manager (RAM).
4
Determine the optimal Savings Plan strategy for compute resources across the organization.
Purchase a Compute Savings Plan at the AWS Organizations management account level.
Compute Savings Plans cover EC2, Fargate, and Lambda. Purchasing at the management account level ensures consolidated billing benefits where unused commitment is shared dynamically across all member accounts.

Key Concept

Multi-account cost optimization requires a combination of precise performance-based right-sizing (ensuring headroom for peak utilization without OOM), high-availability networking design, and selecting Compute Savings Plans at the AWS Organizations management level for dynamic sharing.
Rate this question