AWS Systems Architect Professional

AWS Compute Optimizer: Rightsizing EC2, EBS, and Lambda – SAP-C02 Study Guide

Learn how AWS Compute Optimizer uses historical utilization data to recommend right-sized EC2, EBS, and Lambda configurations for better cost and performance decisions.

AWS Systems Architect ProfessionalAWS Systems Architect ProfessionalUpdated Sep 1, 2026
Study options
WatchComing later
ListenComing later
ReadAvailable
ReviewComing later

Study guide

Technical reference and lesson notes

Purpose of This Lesson

AWS Compute Optimizer helps identify whether selected AWS compute resources are underprovisioned, overprovisioned, or appropriately sized. It analyzes historical utilization data and produces recommendations intended to improve performance and reduce unnecessary cost.

The service is primarily a decision-support tool: it recommends resource configurations, but an engineer must validate the recommendation against workload behavior, availability requirements, compatibility, and operational constraints before implementing it.

Key Concepts

What AWS Compute Optimizer Does

Compute Optimizer uses machine learning and historical utilization metrics to recommend more suitable resource configurations. The recommendations can help answer questions such as:

  • Is an EC2 instance larger than the workload requires?
  • Is a workload constrained by CPU, memory, or another resource characteristic?
  • Could an alternative instance type reduce cost while maintaining acceptable performance?
  • Is a Lambda function configured with more or less memory than its workload needs?
  • Are EBS volumes provisioned with unsuitable characteristics for their workload?

Recommendations are available through the AWS Management Console and command-line interfaces.

Supported Resource Categories

The lesson focuses on optimization guidance for:

  • Amazon EC2 instances: Recommendations can identify overprovisioned or underprovisioned instances and suggest a different instance type.
  • EC2 Auto Scaling groups: Compute Optimizer can provide optimization findings and recommendations for instances managed through Auto Scaling groups.
  • Amazon EBS volumes: Recommendations can help evaluate whether volume configuration is appropriate for observed workload usage.
  • AWS Lambda functions: Recommendations can help assess function memory configuration and its effect on cost and performance.

Overprovisioned Versus Underprovisioned

An overprovisioned resource has more capacity than the workload generally needs. This can create avoidable cost, especially when the resource runs continuously.

An underprovisioned resource does not provide enough capacity for its workload. Downsizing an underprovisioned resource can worsen latency, throughput, error rates, or application stability.

A resource marked optimized does not necessarily require no further review. It means the observed configuration aligns reasonably with the available recommendation analysis and historical usage data.

Historical Metrics Matter

Compute Optimizer bases recommendations on historical utilization data, including metrics available through Amazon CloudWatch. The quality of a recommendation depends on whether the observation period represents the workload’s real operating conditions.

A workload with strong daily, weekly, seasonal, or event-driven variation may need additional engineering review. A recommendation based only on a quiet period may not be appropriate for peak traffic or business-critical processing windows.

Recommendation Details

At the resource level, recommendations can include information such as:

  • The resource identifier
  • The current configuration or instance type
  • Whether the resource is overprovisioned or underprovisioned
  • A recommended configuration or instance type
  • Estimated cost impact or savings

For example, a recommendation may indicate that an EC2 instance can move from a larger instance type to a smaller, less expensive type. The recommendation is not an automatic migration; it is an input to a rightsizing change plan.

Exam-Relevant Takeaways

  • AWS Compute Optimizer is a cost and performance optimization service, not a general monitoring replacement.
  • It analyzes historical utilization metrics to generate recommendations.
  • It provides guidance for EC2 instances, EC2 Auto Scaling groups, EBS volumes, and Lambda functions.
  • An overprovisioned resource may waste money, while an underprovisioned resource may cause performance or reliability problems.
  • Recommendations are available in the AWS Management Console and through the CLI.
  • A recommended change should be validated against peak utilization, application behavior, availability requirements, and compatibility before implementation.
  • Compute Optimizer can identify a likely better configuration, but it does not eliminate the need for change management, testing, and rollback planning.

Architecture Decision Guide

SituationHow Compute Optimizer helpsEngineering decision still required
EC2 instances appear oversizedSuggests a smaller or otherwise more suitable instance typeConfirm peak CPU, memory, network, storage, and application compatibility
EC2 instances appear undersizedIdentifies possible capacity constraints and recommends a larger or different configurationDetermine whether scaling out, caching, architectural changes, or a different instance family is preferable
Instances are managed by an Auto Scaling groupProvides group or instance optimization findingsConsider scaling policies, minimum capacity, Availability Zone distribution, and deployment procedures
EBS configuration may not match workload needsProvides volume optimization guidance based on observed usageValidate IOPS, throughput, latency, burst behavior, durability, and workload requirements
Lambda functions use a fixed memory settingRecommends a potentially more suitable memory configurationTest duration, concurrency, timeout behavior, downstream load, and total invocation cost
A recommendation shows substantial savingsHighlights a potential cost-reduction opportunityVerify that the observation period includes production peaks and failure scenarios

Common Exam Traps

  • Treating a recommendation as an automatic change: Compute Optimizer provides recommendations. It does not mean the resource has already been resized.
  • Optimizing only for the lowest hourly price: A cheaper instance may have insufficient CPU, memory, network, or storage performance.
  • Ignoring peak demand: Historical averages can hide traffic spikes, batch windows, and seasonal activity.
  • Assuming overprovisioned means safe to downsize immediately: Capacity may be intentionally reserved for failover, deployments, sudden demand, or compliance requirements.
  • Confusing monitoring with optimization: CloudWatch supplies metrics and alarms; Compute Optimizer analyzes utilization to recommend configurations.
  • Forgetting Auto Scaling behavior: Rightsizing an instance type does not replace correct target tracking, step scaling, minimum capacity, or Availability Zone design.
  • Assuming a recommendation guarantees application compatibility: AMI requirements, architecture type, licensing, kernel support, device drivers, and performance characteristics must still be checked.
  • Using a short or unrepresentative observation period: A recommendation from an idle period may be unsuitable for production peaks.

Real-World Engineer Notes

  • Start with workloads that have clear, stable utilization patterns and meaningful cost impact.
  • Review the utilization dimension that is actually limiting the workload. A low average CPU value does not prove that an instance is oversized if memory, network, or storage latency is the bottleneck.
  • For Auto Scaling groups, assess the entire scaling design rather than changing one instance in isolation.
  • Apply changes gradually using a controlled deployment, canary, or replacement strategy where appropriate.
  • Compare post-change performance, error rates, latency, throughput, and cost against the previous baseline.
  • Retain rollback capability. Rightsizing should not compromise availability or recovery capacity.
  • Treat recommendations as evidence, not as architectural requirements. A workload may be intentionally overprovisioned for resilience, burst handling, or operational simplicity.
  • Revisit recommendations as workload behavior, traffic patterns, and application versions change.

Quick Reference Summary

  • Service: AWS Compute Optimizer
  • Primary purpose: Recommend better resource configurations to reduce cost and improve performance
  • Analysis basis: Historical utilization metrics, including CloudWatch data
  • Resource categories: EC2 instances, EC2 Auto Scaling groups, EBS volumes, and Lambda functions
  • Typical findings: Underprovisioned, overprovisioned, or optimized
  • Outputs: Current configuration, recommended configuration, resource identifiers, and estimated cost impact
  • Access methods: AWS Management Console and CLI
  • Important limitation: Recommendations require validation and are not a substitute for capacity planning or application testing

Flashcards

  1. Q: What is the primary purpose of AWS Compute Optimizer?

A: To analyze historical utilization and recommend resource configurations that can improve performance and reduce cost.

  1. Q: Which AWS resource categories are covered in this lesson?

A: EC2 instances, EC2 Auto Scaling groups, EBS volumes, and Lambda functions.

  1. Q: What does an overprovisioned finding indicate?

A: The resource appears to have more capacity than the workload needs, creating a potential cost-optimization opportunity.

  1. Q: What does an underprovisioned finding indicate?

A: The resource may not have enough capacity for its workload and may require a larger or different configuration.

  1. Q: What type of data does Compute Optimizer analyze?

A: Historical utilization metrics, including metrics available through Amazon CloudWatch.

  1. Q: Can Compute Optimizer automatically resize an EC2 instance?

A: No. It provides recommendations; implementation requires engineering validation and a change process.

  1. Q: Why can downsizing based only on average utilization be dangerous?

A: Averages can hide peak traffic, batch processing, failover capacity, or other periods when more resources are required.

  1. Q: Where can Compute Optimizer recommendations be viewed?

A: In the AWS Management Console or through CLI interfaces.

  1. Q: What should be checked before adopting an EC2 instance recommendation?

A: CPU, memory, network, storage behavior, architecture compatibility, peak demand, licensing, and availability requirements.

  1. Q: Does an optimized finding mean that no capacity planning is necessary?

A: No. It indicates that the observed configuration aligns with the recommendation analysis, but future demand and resilience requirements still need review.

Practice Questions

Question 1

A company discovers that many production EC2 instances have low observed utilization and wants AWS guidance on whether smaller instance types may be suitable. Which service best addresses this requirement?

A. AWS Trusted Advisor only
B. AWS Compute Optimizer
C. AWS Config
D. Amazon Inspector

Correct answer: B. AWS Compute Optimizer

Explanation: Compute Optimizer analyzes historical utilization metrics and recommends resource configurations for EC2 and other supported resource types. AWS Config evaluates configuration compliance, while Amazon Inspector focuses on vulnerability and exposure assessment.

Question 2

An operations team receives a Compute Optimizer recommendation to downsize an EC2 instance. The instance has low average CPU utilization, but the application experiences monthly end-of-period traffic spikes. What should the team do first?

A. Immediately apply the recommendation to reduce cost
B. Disable CloudWatch metrics because they are not needed after the recommendation
C. Validate peak-period CPU, memory, network, and application performance before changing the instance
D. Replace the instance with a Spot Instance

Correct answer: C. Validate peak-period CPU, memory, network, and application performance before changing the instance

Explanation: Recommendations are based on historical observations and must be checked against representative peak behavior. Low average CPU alone does not establish that downsizing is safe.

Question 3

A company wants to optimize Lambda memory settings using observed workload behavior. Which statement best describes the role of Compute Optimizer?

A. It automatically rewrites the function code to reduce memory use
B. It recommends a potentially more suitable Lambda configuration based on historical utilization
C. It guarantees the lowest total cost for every invocation pattern
D. It replaces the need for CloudWatch metrics

Correct answer: B. It recommends a potentially more suitable Lambda configuration based on historical utilization

Explanation: Compute Optimizer provides optimization guidance for Lambda functions. Engineers must still test duration, concurrency, timeout behavior, downstream effects, and total cost.

Question 4

An Auto Scaling group receives an optimization recommendation for a smaller EC2 instance type. Which additional consideration is most important before implementing the change?

A. Whether the group’s scaling policies and minimum capacity still support availability requirements
B. Whether all CloudTrail events can be deleted
C. Whether S3 bucket versioning is enabled
D. Whether the VPC has a public subnet

Correct answer: A. Whether the group’s scaling policies and minimum capacity still support availability requirements

Explanation: Changing an instance type does not replace correct Auto Scaling behavior. The team must verify capacity, scaling thresholds, Availability Zone distribution, and deployment or replacement procedures.

Question 5

A Compute Optimizer report classifies a resource as overprovisioned. Which conclusion is most accurate?

A. The resource is guaranteed to be safe to downsize immediately
B. The resource should be deleted
C. The resource may have excess capacity based on observed utilization and should be evaluated for rightsizing
D. The resource has a security vulnerability

Correct answer: C. The resource may have excess capacity based on observed utilization and should be evaluated for rightsizing

Explanation: An overprovisioned finding identifies a potential optimization opportunity. It does not account for every business, resilience, peak-load, licensing, or compatibility requirement, so the recommendation requires engineering review.