CLOUD CONCEPT

Vertical Scaling

Vertical scaling changes the capacity of an existing compute resource or database instance by increasing or decreasing its allocated resources rather than changing the number of instances.

Cloud Concepts Hub →

What is Vertical Scaling

Vertical scaling adjusts resources such as CPU and memory to match a workload's requirements while preserving its single-instance execution model. It can improve performance without application redesign, but engineers must account for resizing interruptions, capacity limits, cost, and the fact that a larger instance does not provide redundancy.

Vertical scaling means scaling up by giving an existing resource more capacity, or scaling down by reducing its capacity. Moving a virtual machine from a configuration with two virtual CPUs and 8 GiB of memory to one with eight virtual CPUs and 32 GiB of memory is a typical example. Horizontal scaling instead adds or removes instances, replicas, or workers. An architecture can combine both approaches: several application servers can each use a larger instance size while their number also changes with demand.

Vertical scaling is useful when a workload needs a larger memory working set, more CPU capacity, or greater per-instance network and storage bandwidth. It often suits legacy applications and relational database writers that cannot easily distribute work across multiple nodes. However, additional CPUs help only when the application can use them. A single-threaded process might benefit more from better per-core performance, while a memory-constrained database might benefit from a larger buffer cache.

Choose a target configuration using measurements rather than CPU utilization alone. Examine memory pressure, swapping, query latency, connection counts, storage latency, throughput, and queue depth. Distinguish compute bottlenecks from storage bottlenecks: increasing database memory will not necessarily resolve an exhausted storage IOPS limit. Provisioned IOPS, storage throughput, and instance-level storage bandwidth are separate capacity-planning dimensions, and the lowest applicable limit can constrain performance.

In Amazon EC2, a common vertical-scaling operation is to stop an EBS-backed instance, change its instance type to a compatible type, and start it again. This interrupts the workload. Check processor architecture, driver compatibility, network configuration, and storage behavior before proceeding. Stopping an instance loses instance-store data, and an automatically assigned public IPv4 address generally changes after stop and start. EC2 hibernation preserves memory state for later resumption on supported configurations; it is not itself a scaling mechanism or a general method for resizing a running workload.

For Amazon RDS, changing the DB instance class adjusts compute and memory capacity. Plan for possible service interruption, select the appropriate maintenance timing, and test client reconnection behavior. A Multi-AZ deployment provides availability protection, but it does not make every class modification interruption-free. Adding read replicas is horizontal read scaling, not vertical scaling, and does not directly increase the primary writer's capacity. RDS storage autoscaling addresses storage growth rather than CPU or memory demand, and allocated storage generally cannot be reduced in place.

Managed services do not all expose scaling in the same way. Aurora Serverless v2 can automatically adjust compute and memory capacity within configured bounds. DynamoDB instead exposes provisioned read and write capacity or on-demand throughput, rather than a database instance size. Increasing DynamoDB capacity units is throughput scaling, not conventional instance-based vertical scaling; partition distribution and hot keys still affect results.

Vertical scaling has a finite ceiling determined by available resource sizes and service limits. It also leaves the workload dependent on the same number of failure domains. Horizontal scaling is often preferable for stateless applications with rapidly changing demand, while vertical scaling can be simpler for stateful or tightly coupled components. Amazon EC2 Auto Scaling normally changes instance count; it does not automatically resize running instances. Adopting a larger instance type through a launch template and instance refresh replaces instances rather than resizing them in place.

For cost optimization, compare the price of a larger instance with the throughput and latency improvement it actually delivers. Scaling down during sustained low demand can reduce waste, but repeated resizing may introduce unacceptable disruption. Maintain headroom, test the change under representative load, and define recovery or rollback procedures. Scalability is the ability to support greater load; elasticity adds timely adjustment as demand changes, which requires automation or operational procedures rather than simply choosing a large instance.

Key aspects of Vertical Scaling

Vertical scaling adjusts per-resource capacity, requiring bottleneck analysis, disruption planning, cost evaluation, and separate availability design.

Capacity changes within a resource

Increase or decrease the resources assigned to an instance instead of changing instance count. CPU, memory, and bandwidth changes depend on the available resource configurations.

Bottleneck-driven sizing

Use workload measurements to determine which resource needs expansion. More CPU will not reliably fix memory pressure, inefficient queries, lock contention, or storage throttling.

Operational disruption and compatibility

Resizing can require a stop, restart, failover, or resource replacement. Validate compatibility and plan maintenance, reconnection, and recovery procedures before changing production capacity.

Finite capacity and unchanged redundancy

The largest supported resource size creates an upper limit. A larger instance does not remove a single point of failure or substitute for replication across failure domains.

Cost and elasticity trade-offs

Larger instances can simplify architecture but may leave expensive unused capacity. Automated vertical scaling is available in some environments, while others require explicit orchestration and tolerate changes poorly.

Complementary scaling dimensions

Combine vertical sizing with horizontal replication and independent storage tuning when appropriate. Database instance classes, provisioned throughput, storage capacity, and IOPS are different controls and should not be treated as interchangeable.

Cloud services for Vertical Scaling

Use EC2 instance sizing for application compute and RDS or Aurora capacity settings for database compute. Evaluate EBS performance where storage is independently configurable, because larger compute resources cannot overcome every storage constraint. Aurora Serverless v2 provides automatic compute-capacity adjustment, whereas provisioned instances require explicit sizing changes. DynamoDB represents a different scaling model: configure throughput behavior rather than selecting a larger database server. Across these services, coordinate capacity changes with monitoring, maintenance planning, and availability controls. Horizontal application scaling, database replicas, and vertical resizing can coexist, but each addresses a different performance or resilience requirement.

Amazon EC2 image Amazon EC2

Change an instance's type to adjust CPU, memory, and associated bandwidth limits, subject to compatibility requirements. A typical resize of an EBS-backed instance requires stopping and starting it; EC2 Auto Scaling primarily changes instance count instead.

Open Amazon EC2 →
Amazon RDS image Amazon RDS

Modify the DB instance class to scale database compute and memory capacity. Treat storage size, Provisioned IOPS, read replicas, and Multi-AZ availability as separate design decisions, and plan for possible interruption during class changes.

Open Amazon RDS →
Amazon Aurora image Amazon Aurora

Provisioned Aurora instances can be resized by changing their DB instance class. Aurora Serverless v2 adjusts compute and memory capacity within configured bounds, while adding Aurora Replicas is a separate horizontal read-scaling mechanism.

Open Amazon Aurora →
Amazon DynamoDB image Amazon DynamoDB

DynamoDB scales throughput through provisioned capacity settings with optional auto scaling, or through on-demand capacity mode. It does not expose an instance class to resize, so capacity-unit increases should not be confused with conventional vertical scaling.

Open Amazon DynamoDB →