AWS Certified Solutions Architect — Associate · SAA-C03

Design Cost-Optimized
Architectures

Domain 4 — Comprehensive Study Guide
Task Statements 4.1 · 4.2 · 4.3 · 4.4 · 4.5

📋 20% of Exam Score · ~13 Questions
Domain 4 Overview

What You Need to Know

Task 4.1 — Cost-Effective Storage
  • S3 storage class selection for cost
  • S3 Lifecycle policies — automate tiering
  • EBS right-sizing and snapshot cleanup
  • EFS Intelligent-Tiering & IA tier
  • S3 Intelligent-Tiering for unknown patterns
Task 4.2 — Cost-Effective Compute
  • EC2 pricing models: On-Demand, Reserved, Spot, Savings Plans
  • Right-sizing with Compute Optimizer
  • Serverless cost model: Lambda, Fargate
  • Auto Scaling to eliminate over-provisioning
  • Graviton (ARM) instances for better price/performance
Task 4.3 — Cost-Effective Databases
  • RDS Reserved Instances
  • Aurora Serverless v2 for variable workloads
  • DynamoDB On-Demand vs. Provisioned cost
  • ElastiCache to reduce database read costs
  • S3 + Athena vs. Redshift cost comparison
Task 4.4 & 4.5 — Network & Managed Services
  • Data transfer pricing patterns
  • VPC Endpoints to eliminate NAT Gateway costs
  • CloudFront to reduce origin data transfer
  • Managed services vs. self-managed cost model
  • Cost allocation tags & monitoring tools
4.1

Cost-Effective Storage Solutions

S3 Storage Classes · Lifecycle Policies · EBS Right-Sizing · EFS IA · Intelligent-Tiering

Task 4.1 — S3 Storage Costs

S3 Storage Class Cost Optimization

Tiering by access frequency · Lifecycle automation · Intelligent-Tiering
S3 Standard
Most $$$
Intelligent-Tiering
Standard-IA
One Zone-IA
Glacier Instant
Glacier Flexible
Deep Archive
Least $$$
Lifecycle Policy Automation
  • Automatically transition objects to cheaper tiers after N days
  • Typical pattern: Standard → Standard-IA (30d) → Glacier (90d) → Deep Archive (180d)
  • Set expiration rules to auto-delete objects past retention period
  • Abort incomplete multipart uploads after N days — prevents hidden cost accumulation
  • Apply to entire bucket or filtered by prefix/tag
S3 Intelligent-Tiering
  • AWS monitors access frequency and moves objects automatically
  • Frequent Access tier ↔ Infrequent Access tier (30-day inactivity threshold)
  • Optional: Archive tiers (90 and 180 days of inactivity)
  • Small monthly monitoring fee per object (~$0.0025/1,000 objects)
  • Best for: data lakes, user uploads, logs — when access pattern is unknown or variable
  • No retrieval fees between Frequent/Infrequent tiers
When to Use Each Tier
  • Standard: Accessed daily/weekly. No minimum duration.
  • Standard-IA: Monthly backups, DR copies. ≥128 KB objects. 30-day min.
  • One Zone-IA: Re-creatable data only (thumbnails). 20% cheaper than Standard-IA. Single AZ risk.
  • Glacier Instant: Medical images, media archives. Accessed ~quarterly. 90-day min.
  • Glacier Flexible: Backups. 3–5 hour retrieval OK. 90-day min.
  • Deep Archive: 7–10 year compliance archive. 12–48h retrieval. 180-day min.
Standard-IA and Glacier tiers charge per-GB retrieval fees — if data is accessed frequently, the retrieval fees exceed the storage savings. Always calculate before choosing IA tiers for hot data.
"Unknown access pattern" → S3 Intelligent-Tiering. "Log files that must be retained 7 years, rarely accessed" → Lifecycle to Deep Archive. "Application backups stored for 30 days, then deleted" → Lifecycle expiration rule. Standard-IA has 30-day minimum storage charge — don't use for short-lived objects.
Task 4.1 — EBS & EFS Costs

Block & File Storage Cost Optimization

EBS right-sizing · Snapshot cleanup · EFS Intelligent-Tiering
EBS Cost Levers
  • Right-size volumes: EBS charges for provisioned size, not used size. Shrink oversized volumes.
  • gp3 over gp2: Same price per GB but gp3 independently provisions IOPS — avoid paying for unused IOPS burst on gp2.
  • st1 / sc1 for sequential workloads: HDD tiers are ~80% cheaper than SSD for the right access pattern (throughput-heavy, not IOPS-heavy).
  • Delete unattached volumes: Terminated EC2 instances may leave orphaned volumes — they still accrue charges. Use AWS Config rule to detect.
  • Snapshot management: Use Data Lifecycle Manager (DLM) to automate snapshot creation and deletion. Delete stale snapshots from older AMIs.
EFS Cost Optimization
  • EFS Intelligent-Tiering: Automatically moves files not accessed for 30 days to EFS IA tier (~92% cheaper than Standard)
  • EFS IA tier: Same durability and availability as Standard; retrieval fee per GB accessed
  • Throughput mode: Elastic Throughput (pay per GB transferred) vs. Provisioned (flat rate) — use Elastic for variable workloads
  • EFS One Zone: Stores data in a single AZ — 47% cheaper than Multi-AZ. Use for dev/test or data that can be recreated.
Storage Cost Monitoring
  • AWS Cost Explorer: Visualize storage costs by service and tag
  • S3 Storage Lens: Organization-wide S3 usage and activity insights
  • Trusted Advisor: Flags unattached EBS volumes, underutilized snapshots
  • Cost Allocation Tags: Tag buckets and volumes by team/project for chargeback
"EC2 instances terminated but costs still high" → check for unattached EBS volumes and old EBS snapshots. "Shared file system costs too high" → enable EFS Intelligent-Tiering or switch to EFS One Zone for dev environments. gp3 costs the same as gp2 but gives more control — always prefer gp3.
4.2

Cost-Effective Compute

EC2 Pricing Models · Savings Plans · Spot Instances · Right-Sizing · Serverless · Graviton

Task 4.2 — EC2 Pricing

EC2 Pricing Models

On-Demand · Reserved · Savings Plans · Spot · Dedicated
On-Demand
Pay per second (Linux) or per hour (Windows). No commitment. Most flexible, highest cost. Use for: short-term, unpredictable workloads; development/testing; new applications being sized. Baseline price — no discount.
Reserved Instances (RI)
1- or 3-year commitment to a specific instance type, OS, and region. Up to 72% discount vs On-Demand. Standard RI: locked to instance type. Convertible RI: can change family/OS/tenancy (up to 66% discount). Payment options: All Upfront (max discount), Partial Upfront, No Upfront.
Savings Plans
Flexible commitment to a $/hour spend level. Compute SP: applies to EC2 (any family/region), Lambda, Fargate — up to 66% discount. EC2 Instance SP: specific instance family + region — up to 72% discount. Recommended over RIs for most use cases due to flexibility.
Spot Instances
Bid on spare EC2 capacity. Up to 90% discount vs On-Demand. AWS can reclaim with 2-minute warning. Use for: fault-tolerant, stateless, flexible start/end time workloads — batch jobs, data processing, rendering, CI/CD, containerized tasks.
Dedicated Hosts / Instances
Physical server dedicated to you. Dedicated Host: you control socket/core placement, bring your own license (BYOL) for SQL Server, Oracle, Windows. Most expensive option. Use only when licensing or compliance requires physical isolation.
"Steady-state 24/7 workload, 1-year plan" → Reserved Instance or Savings Plan. "Batch jobs that can be interrupted" → Spot Instances. "Need to bring SQL Server license from on-premises" → Dedicated Host. "Mixed fleet flexibility across families and regions" → Compute Savings Plan over Standard RI.
Task 4.2 — Commitment Discounts

Savings Plans vs. Reserved Instances

Choosing the right commitment model for long-running workloads
Feature Compute Savings Plan EC2 Instance Savings Plan Standard Reserved Instance
Max DiscountUp to 66%Up to 72%Up to 72%
Applies toEC2 (any family/region), Lambda, FargateEC2 specific instance family + regionSpecific instance type + OS + region
FlexibilityHighest — change instance family, size, region, OS, tenancyChange size and OS within familyLocked — cannot change instance type or region
Commitment$/hour spend level, 1 or 3 years$/hour spend level, 1 or 3 yearsInstance quantity, 1 or 3 years
MarketplaceNot resaleableNot resaleableCan sell unused capacity on RI Marketplace
Best forMixed workloads, microservices, containers + serverlessSteady EC2 workload, family flexibility neededExact instance type known long-term; want max discount
Savings Plans are recommended over RIs for most new workloads due to flexibility. Use Standard RI only when the exact instance type is known for years and you want to use the RI Marketplace. Compute Savings Plan covers Lambda and Fargate — RIs do not.
Task 4.2 — Spot Instances

Spot Instances — Maximum Savings for Flexible Workloads

Up to 90% discount · Interruption handling · Spot Fleet strategies
Spot — Good Fit ✅
  • Batch data processing (ETL, analytics, log processing)
  • Image / video rendering and transcoding
  • CI/CD build and test pipelines
  • Containerized microservices (stateless)
  • HPC / scientific simulation workloads
  • Machine learning model training
  • Background workers behind an SQS queue
  • Dev / test environments (acceptable downtime)
Spot — Poor Fit ❌
  • Stateful databases (RDS, production databases)
  • Production web servers handling live user traffic alone
  • Applications with no checkpointing or restart capability
  • Long-running jobs that cannot be safely interrupted mid-way
  • Any workload with an SLA requiring high availability
Spot Fleet & Interruption Handling
  • Spot Fleet: Request Spot across multiple instance types + AZs simultaneously — reduces interruption risk
  • 2-minute warning: CloudWatch event + instance metadata → gracefully checkpoint and drain
  • Spot + On-Demand mix: ASG with base capacity On-Demand/Reserved, overflow on Spot
  • Capacity Rebalancing: Proactively replace Spot instances at elevated interruption risk
"Batch jobs that can be interrupted" → Spot. "Workers behind SQS processing images" → Spot ASG on queue depth. The pattern for resilient Spot is: diversify across instance types + AZs, handle the 2-minute warning, and use SQS/checkpointing so interrupted work can resume. Never use Spot as the only compute for user-facing production services.
Task 4.2 — Right-Sizing & Architecture

Right-Sizing, Graviton & Serverless Cost Models

Compute Optimizer · ARM instances · Lambda pay-per-use
AWS Compute Optimizer
  • Analyzes CloudWatch metrics to identify over-provisioned resources
  • Recommends optimal EC2 instance type, EBS volume type, Lambda memory, ECS task sizing, and ASG configuration
  • Free tier: account-level. Enhanced mode: cross-account, 3-month lookback, Graviton recommendations
  • Also available via Trusted Advisor (low-utilization EC2)
  • Act on recommendations to reduce cost without impacting performance
AWS Graviton (ARM) Instances
  • AWS-designed ARM64 processors: Graviton2 (M6g, C6g, R6g), Graviton3 (M7g, C7g, R7g)
  • Up to 40% better price/performance vs equivalent Intel/AMD x86 instances
  • Works with: Linux workloads, containerized apps, JVM, Python, Node, Go
  • Not compatible with: Windows, some legacy binaries requiring x86
  • Supported for Lambda (arm64 architecture — 20% cheaper than x86)
Serverless Cost Model
  • Lambda: Pay per invocation ($0.20/1M) + duration ($0.0000166667/GB-sec). Zero cost when idle. Scales to zero automatically.
  • Fargate: Pay per vCPU-hour + GB-hour per task. No idle cluster cost.
  • vs. EC2: Serverless eliminates cost of idle compute. Break-even depends on utilization — EC2 RI is cheaper at sustained high utilization; serverless is cheaper at low/variable utilization.
"Identify underutilized EC2 instances" → AWS Compute Optimizer or Trusted Advisor. "20–40% cost reduction without code changes" → migrate to Graviton (ARM) instances. "Workload runs only occasionally, not 24/7" → Lambda or Fargate eliminates idle compute cost vs. always-on EC2.
4.3

Cost-Effective Database Solutions

RDS Reserved · Aurora Serverless · DynamoDB Cost Modes · Caching to Reduce DB Spend

Task 4.3 — Database Costs

Database Cost Optimization

RDS Reserved · Aurora Serverless · DynamoDB Capacity · ElastiCache ROI
RDS Cost Levers
  • RDS Reserved Instances: 1- or 3-year commitment on RDS instance class. Up to 69% discount vs. On-Demand. Apply to Multi-AZ deployments too.
  • Right-size instance class: Use Performance Insights + CloudWatch to find underutilized RDS instances. CPU <40% and low connections → downsize.
  • Stop dev/test instances: RDS can be stopped for up to 7 days — saves compute cost while retaining storage.
  • Aurora vs. RDS MySQL: Aurora storage is auto-scaled and billed per GB used; RDS requires pre-allocated storage. For large DBs with variable growth, Aurora storage billing can be more cost-effective.
  • Single-AZ for dev/test: Multi-AZ doubles instance cost. Use Single-AZ for non-production.
Aurora Serverless v2
  • Scales from 0.5 to 128 Aurora Capacity Units (ACUs) instantly
  • Billed per ACU-second — no cost for idle capacity between requests
  • Best for: development, variable workloads, intermittent traffic (SaaS multi-tenant, seasonal apps)
  • Can auto-pause to 0 when idle (dev/test) — zero compute cost
  • Minimum ACU billing prevents true zero cost in production
DynamoDB: On-Demand vs. Provisioned
  • On-Demand: Pay per request. No capacity planning. Higher per-RCU/WCU cost but zero idle cost. Best for unpredictable traffic.
  • Provisioned + Auto Scaling: Set min/max RCUs/WCUs; auto scaling adjusts. Cheaper at sustained, predictable load. Best for consistent traffic patterns.
  • Reserved Capacity: Commit to provisioned throughput for 1–3 years. Up to 76% discount. Use for stable read/write-heavy tables.
"RDS running 24/7 for production, stable load" → RDS Reserved Instance. "Aurora database for a new SaaS app with unknown initial traffic" → Aurora Serverless v2. "DynamoDB table serving consistent high traffic" → Provisioned capacity + Reserved Capacity for max savings. Add ElastiCache in front of any read-heavy RDS/Aurora to dramatically reduce DB instance sizing.
4.4 · 4.5

Network Cost Optimization & Managed Services

Data Transfer Pricing · VPC Endpoints · CloudFront · Managed Service TCO

Task 4.4 — Network Costs

Data Transfer Cost Patterns

What's free · What costs money · How to reduce it
Free Data Transfer $0
  • Inbound to AWS from the internet (ingress is always free)
  • Within the same AZ (same AZ, same region) using private IPs
  • S3 → CloudFront (origin fetch from S3 is free)
  • EC2 ↔ S3 in same region (via internet endpoint or Gateway Endpoint)
  • Between services in the same region using Gateway Endpoints (S3, DynamoDB)
  • Direct Connect data-in from on-premises to AWS
Charged Data Transfer $$
  • Outbound from AWS to the internet (egress) — charged per GB
  • Cross-AZ traffic within the same region — charged both ways
  • Cross-region data transfer — charged per GB
  • NAT Gateway processing — charged per GB processed + hourly
  • VPC Peering cross-region — charged per GB
  • Direct Connect data-out from AWS to on-premises — charged per GB
VPC Endpoint Cost Savings
  • Gateway Endpoints (S3, DynamoDB): Free. Eliminates NAT Gateway processing charges for traffic to S3/DynamoDB from private subnets — potentially hundreds of dollars/month saved.
  • Interface Endpoints: Hourly charge per AZ + per GB. Cheaper than routing through NAT Gateway for high-volume service traffic.
CloudFront to Reduce Egress
  • CloudFront → internet egress is priced lower than direct EC2/S3 → internet
  • S3 → CloudFront origin fetch is free — only egress from CloudFront to users is charged
  • Cache hit ratio: every cache hit eliminates both origin compute and egress cost
  • Price Classes: restrict CloudFront to cheaper edge regions (e.g., North America only) if users are concentrated geographically
"EC2 in private subnet accessing S3 — high NAT Gateway costs" → Add S3 Gateway VPC Endpoint (free) to bypass NAT Gateway. "High internet egress costs for static assets" → Put CloudFront in front — cheaper egress rates + cache hits eliminate repeat egress. Cross-AZ traffic costs money — consolidate into fewer AZs only if HA requirements allow.
Task 4.5 — Managed Services

Managed Services vs. Self-Managed TCO

Reducing operational overhead as a cost optimization strategy
Amazon RDS vs. EC2 + MySQL RDS manages patching, backups, Multi-AZ failover, and parameter tuning. Self-managed MySQL on EC2 requires DBAs for these tasks. Even at higher sticker cost, RDS often has lower TCO when engineering time is valued.
AWS Lambda vs. EC2 workers Lambda eliminates idle compute cost and all server management. No OS patching, capacity planning, or scaling configuration. Engineers focus on business logic. Best for variable, event-driven workloads.
Amazon ECS/Fargate vs. self-managed Kubernetes Fargate eliminates EC2 cluster management for containers. EKS with managed node groups reduces Kubernetes control plane overhead. Fargate has higher per-vCPU cost but zero cluster management cost — compare against team time to manage clusters.
Amazon OpenSearch vs. self-managed Elasticsearch OpenSearch Service handles cluster provisioning, patching, snapshots, and scaling. Self-managed Elasticsearch requires dedicated DevOps effort. Managed service pricing often justified by elimination of operational overhead.
AWS Cost Management Tools
  • AWS Cost Explorer: Visualize spend over time; forecast future costs; identify top cost drivers by service, region, tag
  • AWS Budgets: Set cost/usage/RI/Savings Plan thresholds; SNS alerts when exceeded
  • Cost Allocation Tags: Tag resources by team, project, environment; enable in billing console for per-tag cost breakdown
  • AWS Trusted Advisor: Cost optimization checks: idle EC2, unattached EBS, underutilized RIs, S3 bucket policy
  • Compute Optimizer: Right-sizing recommendations for EC2, Lambda, ECS, EBS
  • Billing Alarms: CloudWatch alarm on EstimatedCharges metric
Cost Optimization Mindset
  • Adopt Cloud Financial Management (CFM) practices
  • Treat cost as a non-functional requirement
  • Right-size before reserving capacity
  • Use spot/serverless before reserving
  • Monitor continuously — cost drifts over time
"Reduce operational overhead" → managed service answer (RDS over EC2+MySQL, Fargate over self-managed Kubernetes, Lambda over EC2 workers). "Alert when monthly spend exceeds $1,000" → AWS Budgets + SNS. "Identify which team is spending the most" → Cost Allocation Tags + Cost Explorer.
Domain 4 — Decision Guide

Cost Optimization Scenario Decision Tree

Map the requirement to the cost-optimal solution
Steady-state EC2 workload running 24/7, 1–3 year horizon
Savings Plan or Reserved Instance
Batch / background jobs that can be interrupted
Spot Instances (up to 90% savings)
Event-driven, infrequent, or variable compute workload
AWS Lambda (pay only for invocations)
EC2 instances appear oversized / CPU consistently low
AWS Compute Optimizer → right-size to smaller type
Linux workload, want 40% better price/performance
Migrate to Graviton (ARM) instance family
S3 data aging — rarely accessed after 30 days
S3 Lifecycle policy to Standard-IA → Glacier
Unknown S3 access patterns — want automatic tiering
S3 Intelligent-Tiering
Private subnet EC2 frequently accesses S3 via NAT Gateway
S3 Gateway VPC Endpoint (free — eliminates NAT processing)
High internet egress costs for static web content
CloudFront CDN (lower egress rate + cache hits)
Alert team when monthly AWS spend exceeds budget
AWS Budgets + SNS notification
Quick Review

Exam Checklist — Domain 4

Can you answer these?
Task 4.1 — Storage Costs
  • S3 storage class selection by access frequency and retrieval SLA
  • S3 Lifecycle policy: transition and expiration rule configuration
  • S3 Intelligent-Tiering for unknown or variable access patterns
  • Standard-IA 30-day minimum charge — don't use for short-lived objects
  • EBS: gp3 over gp2; delete unattached volumes; DLM for snapshots
  • EFS Intelligent-Tiering and One Zone for cost reduction
Task 4.2 — Compute Costs
  • On-Demand (flexible) → RI / Savings Plan (committed) → Spot (interruptible)
  • Compute Savings Plan covers EC2 + Lambda + Fargate; RIs do not
  • Spot: up to 90% savings; 2-min warning; SQS for resilient worker pattern
  • Graviton ARM instances: ~40% better price/perf on Linux workloads
  • Compute Optimizer for right-sizing EC2, Lambda memory, EBS volume type
  • Lambda: zero idle cost; scales to zero automatically
Task 4.3 — Database Costs
  • RDS Reserved Instances for stable, always-on production databases
  • Aurora Serverless v2 for variable or intermittent workloads
  • DynamoDB Provisioned + Reserved Capacity for predictable high-traffic tables
  • ElastiCache in front of RDS to reduce instance sizing requirements
  • Stop dev/test RDS instances outside business hours to save compute
Tasks 4.4 & 4.5 — Network & Managed Services
  • Cross-AZ traffic costs money — same-AZ communication is free
  • S3 Gateway VPC Endpoint is free — eliminates NAT Gateway processing cost
  • CloudFront reduces egress costs; S3 → CloudFront origin fetch is free
  • AWS Budgets for spend alerts; Cost Explorer for analysis; Compute Optimizer for right-sizing
  • Cost Allocation Tags must be activated in billing console before appearing in Cost Explorer
  • Managed services (RDS, Lambda, Fargate) reduce operational overhead = lower TCO
Quick Reference

Cost Optimization Service Quick Map

Compute Pricing Models
  • On-Demand → flexible, short-term, unpredictable
  • Reserved Instance → 1–3yr, specific type, max discount
  • Savings Plan → 1–3yr spend commit, flexible types
  • Spot → interruptible, batch/background, 90% savings
  • Dedicated Host → BYOL, physical isolation compliance
  • Lambda / Fargate → pay-per-use, zero idle cost
Storage Cost Tools
  • S3 Lifecycle → automate tier transitions & expiry
  • S3 Intelligent-Tiering → auto-tier unknown patterns
  • S3 One Zone-IA → re-creatable data, 20% cheaper
  • S3 Glacier Deep Archive → 7–10yr compliance, cheapest
  • EBS gp3 → decouple IOPS from size; same price as gp2
  • EFS One Zone + IA tier → dev/cold file storage
Right-Sizing Tools
  • Compute Optimizer → EC2, EBS, Lambda, ECS sizing
  • Trusted Advisor → idle EC2, unattached EBS, low-util RIs
  • Graviton (M6g, C6g, R6g) → 40% better price/perf
  • Lambda arm64 → 20% cheaper than x86
  • Performance Insights → find undersized/oversized RDS
  • CloudWatch + ASG → eliminate idle over-provisioning
Network Cost Reduction
  • S3 Gateway Endpoint → free; no NAT processing fees
  • CloudFront → lower egress rate + cache hit savings
  • CloudFront Price Classes → restrict to cheap regions
  • Same-AZ communication → avoid cross-AZ charges
  • Direct Connect → predictable, potentially cheaper egress
  • VPC Interface Endpoint → cheaper than NAT at volume
Cost Monitoring & Governance
  • AWS Cost Explorer → visualize & forecast spend
  • AWS Budgets → threshold alerts via SNS/email
  • Cost Allocation Tags → per-team/project chargeback
  • S3 Storage Lens → org-wide S3 cost insights
  • AWS Organizations → consolidated billing + RI sharing
  • Billing alarms → CloudWatch EstimatedCharges metric
Database Cost Levers
  • RDS Reserved Instances → 69% savings for stable DBs
  • Aurora Serverless v2 → elastic, pay-per-ACU-second
  • DynamoDB Reserved Capacity → 76% off for stable tables
  • ElastiCache → reduce DB read load → downsize DB
  • Stop dev RDS instances → save compute outside hours
  • Single-AZ → dev/test; Multi-AZ only where HA required

Domain 4 Complete · All Domains Covered

You're ready for Domain 4

20% of SAA-C03 · Design Cost-Optimized Architectures
Good luck on the exam!

4.1 — Cost-Effective Storage 4.2 — Cost-Effective Compute 4.3 — Cost-Effective Databases 4.4 — Network Cost Optimization 4.5 — Managed Services TCO

Domain 1: Secure (30%) · Domain 2: Resilient (26%) · Domain 3: Performing (24%) · Domain 4: Cost (20%)