interview-prep

Crisp answer: RDS is managed versions of open-source and commercial databases on dedicated instances. Aurora is AWS's own cloud-native database engine compatible with MySQL and PostgreSQL but with a distributed storage architecture that delivers higher performance, availability, and scalability.

RDS:

- Engines: PostgreSQL, MySQL, MariaDB, Oracle, SQL Server
- Runs on EC2 instances you choose (db.t3.micro to db.r6g.16xlarge)
- Storage: EBS-backed, scales manually or with storage autoscaling
- Multi-AZ: synchronous standby replica in another AZ, automatic failover
- Read replicas: asynchronous replicas for read scaling (up to 5)
- Failover time: 60-120 seconds for Multi-AZ

Aurora:

- Engines: PostgreSQL-compatible, MySQL-compatible
- Storage: distributed across 6 copies in 3 AZs automatically
- Separates compute (instances) from storage (distributed volume)
- Up to 15 read replicas (vs 5 for RDS)
- Failover: 30 seconds (vs 60-120 for RDS) — storage not re-copied
- Storage: auto-grows in 10GB increments up to 128TB
- Global Database: replicate across regions for DR
- Aurora Serverless v2: scale compute up and down automatically including to zero

Aurora Serverless v2 — what Mimecast likely uses for dev/non-critical:

- min_capacity: 0 ACU (scale to zero, cold start ~10-20s)
- max_capacity: up to 256 ACU
- Scales in fine-grained 0.5 ACU increments
- PostgreSQL 16.4 required for min_capacity=0 (scale-to-zero)
- Cost: $0.12/ACU-hour (compared to fixed instance size for RDS)
- For production: set min_capacity=0.5 to avoid cold start

When to choose each:

RDS PostgreSQL:   Existing workloads, simpler ops, lower cost for stable load
Aurora PostgreSQL: New workloads, need HA, need read replicas, variable load
Aurora Serverless: Dev/test environments, infrequent workloads, cost optimisation

Common operational tasks:

# Check cluster status
aws rds describe-db-clusters --db-cluster-identifier my-cluster --region eu-west-2

# Failover (test or maintenance)
aws rds failover-db-cluster --db-cluster-identifier my-cluster

# Create a manual snapshot
aws rds create-db-cluster-snapshot \
  --db-cluster-identifier my-cluster \
  --db-cluster-snapshot-identifier my-snapshot-$(date +%Y%m%d)

# Restore from snapshot
aws rds restore-db-cluster-from-snapshot \
  --db-cluster-identifier restored-cluster \
  --snapshot-identifier my-snapshot-20250601 \
  --engine aurora-postgresql \
  --engine-version 16.4

# Check parameter group settings
aws rds describe-db-cluster-parameters --db-cluster-parameter-group-name default.aurora-postgresql16

What to say in the interview:

"Aurora and RDS are both managed databases but Aurora has a fundamentally different architecture: it separates compute from storage and replicates storage across six copies in three AZs automatically. This gives faster failover (30 seconds vs 60-120), more read replicas (15 vs 5), and storage that grows automatically. For new PostgreSQL workloads I default to Aurora. Aurora Serverless v2 is particularly useful for dev environments and variable workloads because it scales to zero and costs nothing when idle — that is exactly what we used in the rag-bedrock project for the pgvector store."


My notes