You can scale your EC2 instances vertically by resizing the instance, or horizontally by launching new instances and adding them to the pool.
You can set up automated horizontal scaling using Amazon EC2 Auto Scaling.
Within Amazon EC2 Auto Scaling, you can use two approaches: dynamic scaling and predictive scaling.
Dynamic scaling responds to changing demand.
Predictive scaling automatically schedules the right number of Amazon EC2 instances based on predicted demand.
You can set limits for how many EC2 instances can run (and charge your account) by setting the minimum, desired and maximum capacity.
If you’ve ever tried to visit a website that wouldn’t load or frequently shut down, the website might be getting more visitors than it could handle. This situation is similar to waiting in a long line at a coffee shop, when there is only one barista to take orders from customers and make all the coffee too. Scalability helps to avoid these situations.
Scalability means beginning with only the resources you need, and then responding to changing demand by adding or decreasing those resources. For example, more computing power would support a website when it's receiving lots of visitors, and the extra resources get removed the moment traffic starts to go back to normal again.
This is a great help for:
Now there are two ways to handle growing demands. You can scale up, or scale out.
If you wanted the scaling process to happen automatically, which AWS service would you use? The AWS service that provides this functionality for Amazon EC2 instances is Amazon EC2 Auto Scaling.
Amazon EC2 Auto Scaling lets you automatically add or remove Amazon EC2 instances in response to changing demand.
Within Amazon EC2 Auto Scaling, you can use two approaches: dynamic scaling and predictive scaling. To scale faster, you can use dynamic scaling and predictive scaling together.
Suppose that you are preparing to launch an application on Amazon EC2 instances. Because you pay for only the EC2 instances you use, you can set limits for how many EC2 instances can run (and charge your account) at once.
When you configure the Auto Scaling group for your instances, you set: