---
title: Autoscaling EC2 instances in AWS
description: Autoscaling EC2 instances in AWS
image: https://blog.e-zest.com/hs-fs/file-3586010250-png/blog-files/auto-scaling-uses-to-launch-amazon-ec2-instances.png
---

[![e-Zest logo\_An accion lab company\_Colour](https://blog.e-zest.com/hubfs/images/Logos%20with%20Tagline/Corporate/SVG/e-Zest%20logo_An%20accion%20lab%20company_Colour.svg "e-Zest logo_An accion lab company_Colour")](https://www.e-zest.com/)

- [WORK](https://www.e-zest.com/our-work)
- [SERVICES](https://www.e-zest.com/our-services) 
    - [Product Engineering](https://www.e-zest.com/digital-product-engineering-services)
    - [Enterprise Data Services](https://www.e-zest.com/enterprise-data-services)
    - [Digital Commerce](https://www.e-zest.com/digital-commerce-services)
    - [Digital Operations](https://www.e-zest.com/digital-operations)
    - [Digital Consulting](https://www.e-zest.com/digital-transformation-consulting-services)
    - [Digital Experience Design](https://www.e-zest.com/digital-experience-design)
- [INSIGHTS](https://blog.e-zest.com/)
- [CAREERS](https://www.e-zest.com/careers)
- [ENTERPRISE DATA SERVICES](https://www.e-zest.com/enterprise-data-services)
- [GENERATIVE AI](https://www.e-zest.com/generative-ai)
- [Healthcare](https://healthcare.e-zest.com)
- [Contact Us](https://www.e-zest.com/contact-us)

- ![Elevating Product Engineering with AI and ML](https://blog.e-zest.com/hubfs/Elevating%20Product%20Engineering%20with%20AI%20and%20ML.jpg)

  [BLOGS](https://blog.e-zest.com)
  
  #### Elevating Product Engineering with AI and ML

  As technology evolves and customer choices broaden, there is an increasing ...

  [Read more](https://blog.e-zest.com/elevating-product-engineering-with-ai-and-ml)
- ![e-Zest – An Accion Labs Company gets Recognition as a Contender in the ISG Provider Lens™ Study on Digital Engineering Services 2024](https://blog.e-zest.com/hubfs/e-Zest%20%E2%80%93%20An%20Accion%20Labs%20Company%20-%20Gets%20Recognition%20as%20a%20Contender%20in%20the%20ISG%20Provider%20LensTM%20Study%20on%20Digital%20Engineering%20Services%202024.jpg)

  [NEWS](https://blog.e-zest.com/news)
  
  #### e-Zest – An Accion Labs Company gets Recognition as a Contender in the ISG Provider Lens™ Study on Digital Engineering Services 2024

  We are delighted to announce that e-Zest – An Accion Labs Company has been ...

  [Read more](https://blog.e-zest.com/news/e-zest-an-accion-labs-company-gets-recognition-as-a-contender-in-the-isg-provider-lens-study-on-digital-engineering-services-2024)
- ![e-Zest Solutions supports Digital Pune Mission](https://blog.e-zest.com/hubfs/blog-files/Digital%20Literacy%20Bus%20e-Zest.png)

  [CSR](https://blog.e-zest.com/csr)
  
  #### e-Zest Solutions supports Digital Pune Mission

  **Pune, India:** e-Zest Solutions, a leading digital technology innovation ...

  [Read more](https://blog.e-zest.com/csr/e-zest-solutions-supports-digital-pune-mission)

- [Work](https://www.e-zest.com/our-work)
- [Services](https://www.e-zest.com/our-services)
- [Insights](https://blog.e-zest.com)
- [Careers](https://www.e-zest.com/careers)
- [Enterprise Data](https://www.e-zest.com/enterprise-data-services)
- [Generative AI](https://www.e-zest.com/generative-ai)
- [Innovations](https://www.e-zest.com/innovations)
- [Healthcare](https://healthcare.e-zest.com)
- [About](https://www.e-zest.com/about-us)
- [Contact](https://www.e-zest.com/contact-us)

- [Blog](https://blog.e-zest.com/)
- [News](https://blog.e-zest.com/news)
- [CSR](https://blog.e-zest.com/csr)

- [![Linkedin Icon](https://blog.e-zest.com/hubfs/icons/linkedin_icon_white.svg)](https://www.linkedin.com/company/e-zest-solutions/)
- [![Twitter Icon](https://blog.e-zest.com/hubfs/twitter-logo-silhouette%20(5).svg)](https://twitter.com/ezest)
- [![Facebook Icon](https://blog.e-zest.com/hubfs/facebook-app-logo%20(4).svg)](https://www.facebook.com/61259256638)
- [![Instagram Icon](https://blog.e-zest.com/hubfs/instagram-logo%20(4).svg)](https://www.instagram.com/ezestsolutions/)
- [![Youtube Icon](https://blog.e-zest.com/hubfs/icons/youtube_icon_white.svg)](https://www.youtube.com/user/ezestcorporate)

[![Go to top icon](https://blog.e-zest.com/hubfs/AA%20Assets/top%20button.svg)](https://blog.e-zest.com/autoscaling-ec2-instances-in-aws/#top)

Hit enter to search or ESC to close

Insights

e-Zest members share technology ideas to foster digital transformation.

- [Blog](https://blog.e-zest.com)
- [News](https://blog.e-zest.com/news)
- [Podcasts](https://www.e-zest.com/podcasts)
- [Healthcare](https://blog.e-zest.com/healthcare)
- [CSR](https://blog.e-zest.com/csr)
- [Whitepaper](https://blog.e-zest.com/whitepaper)
- [Playbook](https://blog.e-zest.com/playbook)
- [Media Kit](https://www.e-zest.com/media-kit)

# Autoscaling EC2 instances in AWS

[Saurabh Phaltane](https://blog.e-zest.com/author/saurabh-phaltane)  Nov 12, 2013

[AWS](https://blog.e-zest.com/topic/aws) [Cloud Computing Services](https://blog.e-zest.com/topic/cloud-computing-services) [Autoscaling EC2](https://blog.e-zest.com/topic/autoscaling-ec2) [Amazon Web Services](https://blog.e-zest.com/topic/amazon-web-services) [cloud computing](https://blog.e-zest.com/topic/cloud-computing-2) [Technology](https://blog.e-zest.com/topic/technology)

- <https://www.linkedin.com/shareArticle?mini=true&url=https://blog.e-zest.com/autoscaling-ec2-instances-in-aws/&title=&summary=&source=>
- <https://twitter.com/intent/tweet?source=https://blog.e-zest.com/autoscaling-ec2-instances-in-aws/&text=Autoscaling%20EC2%20instances%20in%20AWS>
- <https://www.facebook.com/sharer/sharer.php?u=https://blog.e-zest.com/autoscaling-ec2-instances-in-aws/>
- <https://www.instagram.com/ezestsolutions/?u=https://blog.e-zest.com/autoscaling-ec2-instances-in-aws/>

Owing to the very simple yet powerful features, Amazon has truly been the most dominating player in the world of cloud and one of the most undisputed super heroes of the cloud market. Out of the many amazing features of Amazon, this blog intends to highlight the auto scaling feature of EC2 instances.

The scaling power that cloud offers us is really powerful; one that requires minimal effort to give optimal resource utilization. Amazon takes a step ahead by further automating the process of scaling up and down your servers on the fly. Achieving optimal use of resources by shutting down the servers with minimal traffic and scaling up in spike time has helped many companies to save thousands of dollars. This blog will explain in a few easy steps how this can be achieved.

The entire autoscaling activity can be explained in four easy steps on the Amazon CLI interface.

**Four Easy Steps to Autoscale instances**

[![Auto Scaling uses to launch Amazon EC2 instances](https://blog.e-zest.com/hs-fs/file-3586010250-png/blog-files/auto-scaling-uses-to-launch-amazon-ec2-instances.png?width=550&height=150&name=auto-scaling-uses-to-launch-amazon-ec2-instances.png)](http://www.e-zest.net/wp-content/uploads/2013/11/Auto-Scaling-uses-to-launch-Amazon-EC2-instances.png)

Specify the template that Auto Scaling uses to launch Amazon EC2 instances.

**as-create-launch-config** my-launch-config --image-id ami-xxxxx --instance-type m1.small --group my-sg-groupname--region region-name--I yourAccesskey --S yourSecretKey

```
my-launch-config: specify a unique template name
ami-xxxxx: Specify the AMI id of the server that you want to spin up
m1.small: specify the type of instance/size for spine up
my-sg-groupname: specify the security group name to be applied to a new spin up instance
```

[![scaling](https://blog.e-zest.com/hs-fs/file-3586010260-png/blog-files/scaling-is-to-be-performed.png?width=250&height=50&name=scaling-is-to-be-performed.png)](http://www.e-zest.net/wp-content/uploads/2013/11/scaling-is-to-be-performed.png)

After creating the template it is necessary to specify where and how the scaling is to be performed.

**as-create-auto-scaling-group** my-autoscaling-grp--launch-configuration my-launch-config--availability-zones us-west-1a,us-east-1a--min-size 1 --max-size 10 --desired-capacity2--load-balancers LoadbalancerName --region region-name--I yourAccesskey --S yourSecretKey

us-west-1a: Specify the zone in which the new instance is to spin. It is always recommended to specify two different availability-zones as a safe practice/disaster recovery.

```
--min-size/--max-size: the minimum number/maximum of instances in your autoscaling group
--desired-capacity: specify the number of instances on startup to be launched
```

[![Action](https://blog.e-zest.com/hs-fs/file-3586010270-png/blog-files/action.png?width=300&height=50&name=action.png)](http://www.e-zest.net/wp-content/uploads/2013/11/action.png)

The third step describes the policy to scale up and scale down.

**as-put-scaling-policy**--auto-scaling-group my-scaleup-policy --name scale-up "--adjustment=1" --type ChangeInCapacity --cooldown 300 --region region-name--I yourAccesskey --S yourSecretKey

```
--adjustment=1: to add 1 new instance to the autoscaling group
--adjustment=-1: to decrease 1 instance from the autoscaling group
--cooldown 300: specify the time lag between the successive triggers of the same policy.
```

**ReturnMessage:**arn:aws:autoscaling:us-west-1:751374139099:scalingPolicy:xxxxxxxx-xxxxx-xxxx-xxxx:autoScalingGroupName/sg-securitygroup-gma:policyName/scale-up

[![when to Launch](https://blog.e-zest.com/hs-fs/file-3586010280-png/blog-files/when-to-launch.png?width=250&height=50&name=when-to-launch.png)](http://www.e-zest.net/wp-content/uploads/2013/11/when-to-Launch.png)

The last step in autoscaling is to specify the condition when the scaling policy is to be triggered which is set using the cloud watch alarms.

After specifying the condition when the alarm should be triggered (here CPU 50%), select the action and the autoscaling group in the relevant combos. The instance is then ready to autoscale.

- <https://twitter.com/intent/tweet?source=https://blog.e-zest.com/autoscaling-ec2-instances-in-aws/&text=Autoscaling%20EC2%20instances%20in%20AWS>
- <https://www.facebook.com/sharer/sharer.php?u=https://blog.e-zest.com/autoscaling-ec2-instances-in-aws/>
- <https://www.linkedin.com/shareArticle?mini=true&url=https://blog.e-zest.com/autoscaling-ec2-instances-in-aws/&title=&summary=&source=>

### Similar Blog

[![AWS IoT - Now Migration is Quick and Easy](https://blog.e-zest.com/hubfs/Blog%20Graphic%20(AWS%20IoT%20migration)%20V5-05.jpg) AWS IoT - Now Migration is Quick and Easy AWS can help make your migration quick and easy Modern businesses employ Internet of Things (IoT) platforms to manage their ... By Mohini Wable Nov 22, 2022](https://blog.e-zest.com/aws-iot-now-migration-is-quick-and-easy)

[![3 Cloud-Native Trends That are Reshaping Our Businesses in 2022](https://blog.e-zest.com/hubfs/e-Newsletter-04.jpg) 3 Cloud-Native Trends That are Reshaping Our Businesses in 2022 The move to the cloud was a trend that was already making headways before the pandemic-led digital shift. But post-2020, the ... By Devendra Deshmukh Feb 22, 2022](https://blog.e-zest.com/3-cloud-native-trends-that-are-reshaping-our-businesses-in-2022)

[![AWS EC2 Assume Role with Terraform](https://blog.e-zest.com/hubfs/blog-files/AWS%20EC2%20Assume%20Role%20with%20Terraform.jpg) AWS EC2 Assume Role with Terraform Nowadays, it is an ideal practice to keep different AWS accounts for IAM users and a different account for running production ... By Vaibhav Khalane Jan 28, 2020](https://blog.e-zest.com/aws-ec2-assume-role-with-terraform)

[![How to enable SMS alerts in Nagios using AWS SNS](https://blog.e-zest.com/hubfs/blog-files/nagios.png) How to enable SMS alerts in Nagios using AWS SNS Nagios is a powerful management and monitoring system. It helps in identifying the IT infrastructure problems. It also helps in ... By Anagha Thorat Feb 06, 2019](https://blog.e-zest.com/how-to-enable-sms-alerts-in-nagios-using-aws-sns)

[Service cloud Einstein to integrate with Amazon Connect Previously, enterprises were highly dependent on paper documentations. Later a huge computer revolution encountered, which ... By Nidhi Thakkar Apr 17, 2017](https://blog.e-zest.com/service-cloud-einstein-to-integrate-with-amazon-connect)

[CloudMap - a 360 Degree Infrastructure control on Cloud Today's Era of cloud is certainly moving in a direction to engulfing 80% of the IT market in coming 5 years. Naturally, it is a ... By Saurabh Phaltane Jun 03, 2014](https://blog.e-zest.com/cloudmap-a-360-degree-infrastructure-control-on-cloud/)

[![Graylog2- Scalable logging solution-VPC Production environments](https://blog.e-zest.com/hs-fs/file-3395304749-png/blog-files/graylog-logger-app-server.png) Graylog2- Scalable logging solution-VPC Production environments Monitoring and tracking the events on cloud is a great topic of interest among system administrators who are in constant search ... By Saurabh Phaltane Feb 03, 2014](https://blog.e-zest.com/graylog2-scalable-logging-solution-vpc-production-environments/)

[![GrayLog2 Centralize your Logs and power of Analytics](https://blog.e-zest.com/hs-fs/file-3395304089-png/blog-files/graylog-setup.png) GrayLog2 Centralize your Logs and power of Analytics **Why Centralized Log Aggregation:** By Saurabh Phaltane Jan 01, 2014](https://blog.e-zest.com/graylog2-centralize-your-logs-and-power-of-analytics/)

[![Manage Your Petabyte Scale Data with AWS Redshift](https://blog.e-zest.com/hs-fs/file-3586008590-jpg/blog-files/amazon-s3.jpg) Manage Your Petabyte Scale Data with AWS Redshift Amazon Redshift provides an extensive framework to analyze our petabyte scale data with optimized cost with our existing BI ... By Saurabh Phaltane Jul 16, 2013](https://blog.e-zest.com/manage-your-petabyte-scale-data-with-aws-redshift/)

## Helping Organizations Thrive in the Digital Age

[Contact Us](https://www.e-zest.com/contact-us)

- [About](https://www.e-zest.com/about-us)
- [Services](https://www.e-zest.com/our-services)
- [Work](https://www.e-zest.com/our-work)
- [Insights](https://blog.e-zest.com/)
- [Healthcare](https://healthcare.e-zest.com/)
- [Accion Labs](https://www.accionlabs.com/)

- <https://www.linkedin.com/company/e-zest-solutions/>
- <https://twitter.com/ezest>
- <https://www.facebook.com/eZest/>
- <https://www.instagram.com/ezestsolutions/>
- <https://www.youtube.com/user/ezestcorporate>

- Dallas
- Detroit
- Hannover
- Vienna
- London
- Pune

 © 2025 e-Zest Solutions

- [Privacy Policy](https://www.e-zest.com/privacypolicy)
- [Cookie Policy](https://www.e-zest.com/cookie-policy)

 Contact us

 Contact us

e-Zest is a leading digital innovation partner for enterprises and technology companies that utilizes emerging technologies for creating engaging customers experiences. Being a customer-focused and technology-driven company, it always helps clients in crafting holistic business value for their software development efforts. It offers software development and consulting services for cloud computing, enterprise mobility, big data and analytics, user experience and digital commerce.