0%
AWS in Practice: Services, Limits, and Failure Modes
Account Foundations
Compute
Storage
Networking
Delivery and Visibility
Limits, Cost and Recovery
RDS and Aurora Architecture
Relational Database Service runs MySQL, PostgreSQL, MariaDB, Oracle, SQL Server and Db2 as managed services. AWS provisions the instance, installs and patches the engine, takes backups, handles failover, and exposes metrics, while the team chooses the instance size, storage, configuration and schema. Knowing where that line falls, what RDS takes off the team's hands and what it leaves, is the starting point for running a relational database on AWS well, because most RDS incidents happen on the team's side of it.
What you still own
RDS manages the operating system, engine installation, minor version patching in maintenance windows, automated backups, storage replication and failover. The team still owns schema design, indexes, query performance, connection management, parameter tuning, choosing the instance class and storage, planning major version upgrades, capacity planning, and access control inside the database. A slow query is still a slow query on RDS, a missing index still causes a full table scan, and too many connections still exhaust memory. Managed does not mean tuned, and teams that expect RDS to handle performance meet the same problems they would on self managed databases, with fewer knobs to fix them.
The split also shows up in incident reviews. When an RDS database has a bad day, the first question worth asking is which side of the line the cause sits on. Hardware failure, a host that needs replacing, or a storage node that degrades are AWS problems, and the managed features handle them, usually with a failover the application has to ride out. A plan that changed after statistics went stale, a migration that added a column with a default to a large table and rewrote it, or a batch job that opened five hundred connections are team problems, and no amount of waiting for AWS fixes them. Teams that keep a short runbook mapping common symptoms to the side that owns them recover faster, because they stop waiting on a support case for something only they can change.
What you give up
RDS does not give shell access to the database host, so tools that need the operating system, custom extensions not on the supported list, and some superuser operations are unavailable. Engine parameters are changed through parameter groups rather than configuration files, and some are fixed. Replication topologies are limited to what RDS supports. For the large majority of applications these limits never matter. When they do, RDS Custom for Oracle and SQL Server offers host access with some managed features, and running the database on EC2 remains possible, at the price of taking on everything RDS would have done.
Instance classes
RDS instances come in classes that mirror EC2: general purpose db.m classes, memory optimised db.r and db.x classes for databases whose working set should fit in memory, and burstable db.t classes for development and small workloads. Graviton based classes, ending in g, offer better price performance for MySQL, PostgreSQL and MariaDB. Memory is usually the most important dimension for a relational database, because a working set that fits in the buffer pool avoids disk reads, so production databases tend toward memory optimised classes. Burstable classes run on CPU credits, and a production database on a db.t instance that exhausts its credits slows to its baseline, a common and avoidable incident.
Sizing a class from metrics, rather than guessing, starts with three numbers from the current database or a load test: the size of the hot data and indexes, the peak CPU under realistic load, and the peak read and write IOPS. The buffer cache hit ratio is the quickest check on memory. A ratio that stays above ninety nine percent under load means the working set fits, while a ratio that drops during busy periods, paired with rising read IOPS, means queries are going to disk and the next class up in memory will help more than more CPU. Freeable memory falling toward zero is a warning that the engine and its connections are squeezing the cache.
Storage
RDS for the non Aurora engines stores data on EBS volumes managed by the service. General purpose gp3 storage is the default, with baseline IOPS and throughput that can be raised. Provisioned IOPS storage, io1 and io2, suits databases with high and consistent I/O needs. Storage autoscaling grows the allocated storage when free space runs low, up to a configured maximum, which prevents the outage of a full disk. Storage cannot be shrunk once allocated, so starting near the expected size and letting autoscaling grow it is better than allocating generously up front. The I/O limits of the instance class apply as they do on EC2, so a large database on a small instance can be limited by the instance rather than the storage.
Storage type choice is usually simpler than it looks. Most production databases do well on gp3 with IOPS and throughput raised to cover measured peaks, which costs far less than provisioned IOPS for the same numbers. io2 earns its price for databases that need very high IOPS with consistent sub millisecond latency, or the higher durability io2 provides, such as large OLTP systems where a latency spike during a busy hour costs real money. Magnetic storage is a legacy option that should not appear in any new design. Whatever the type, the CloudWatch metrics ReadIOPS, WriteIOPS, ReadLatency, WriteLatency and DiskQueueDepth show whether storage is the bottleneck, and a queue depth that stays high while latency climbs is the clearest sign.
Parameter groups and option groups
Database configuration lives in parameter groups, named sets of engine parameters attached to instances. The default parameter group cannot be modified, so every production database should use a custom group from the start, even if it initially matches the default, because switching groups later requires a reboot. Some parameters apply immediately and others only after a reboot, which RDS shows as pending. Option groups enable engine features such as Oracle's Transparent Data Encryption or SQL Server's native backup to S3. Keeping parameter groups in infrastructure as code, with comments explaining each change, stops configuration drift between environments.
Networking and access
An RDS instance lives in a DB subnet group spanning at least two zones in a VPC, and should almost always be in private subnets with no public access. Security groups control which clients can connect on the database port. Authentication can use database users with passwords, ideally stored in Secrets Manager with automatic rotation, or IAM database authentication for MySQL and PostgreSQL, which issues short lived tokens from IAM credentials. TLS should be required for connections, which PostgreSQL enforces with rds.force_ssl and MySQL with require_secure_transport. A public database protected only by a password is one of the most common findings in cloud security reviews.
Credentials deserve the same care as network placement. The master user created with the instance has broad privileges and should be used only for administration, with each application getting its own database user that can read and write only the tables it needs. Secrets Manager can rotate the master password automatically through RDS's managed integration, and application credentials through a rotation function, which turns a leaked password from a permanent problem into one that expires. IAM authentication goes further, because tokens last fifteen minutes and are issued from the caller's role, so no long lived database password exists for the application at all. It suits services with modest connection rates, since each new connection needs a token and IAM authentication has a per second connection limit.
Maintenance windows and patching
RDS applies minor version upgrades and operating system patches during a weekly maintenance window chosen by the team, if automatic minor version upgrade is enabled. Most patches require a restart, which on a Single AZ instance means downtime of a few minutes and on Multi AZ means a failover. Choosing a window when traffic is lowest, enabling Multi AZ so patching costs a failover rather than an outage, and watching pending maintenance in the console or through events keeps patching predictable. Deferring patches indefinitely is possible for some, but eventually AWS applies mandatory updates on its own schedule.
Events and notifications close the loop. RDS publishes events for failovers, reboots, backups, configuration changes, low storage and pending maintenance, and an EventBridge rule can route the important ones to a chat channel or a paging system. A team that learns about a failover from customers, rather than from an event it subscribed to, has missed the cheapest monitoring available. Pairing the event feed with a few alarms, on CPU, freeable memory, free storage, connections and replica lag, gives early warning for most of the problems in this section before they become incidents.
RDS runs the host, the engine install, backups, patching and failover. The team still owns schema, indexes, queries, connections, parameters, instance size and upgrade planning, so slow queries and exhausted connections are still the team's problem on RDS.