Helpful Tips for EC2 Rightsizing

Rightsizing and Its Effects on Cost Optimization

Rightsizing is the definitive method to save costs on AWS EC2 or RDS instances and it is achieved by ensuring that your employed machines are all exactly what is needed to meet the capacity requirement and performance of the workloads. Nothing more, nothing less.

Rightsizing starts with monitoring and analyzing your current services being used. An observation period of at least two weeks or maybe even a month will give you sufficient information on the instance performance and usage patterns while also showing you the peak of your workload. 


The metrics that define instance performance include:


  • vCPU utilization
  • Memory utilization
  • Network utilization
  • Disk usage


What are the steps to Rightsizing an AWS environment?

Chart a plan for your EC2 Project

A project goal is essential in determining beforehand what the resources you need will be. A large cloud environment will be laden with multiple applications, servers, and databases. All these resources will be built upon On-demand, reserved, or spot instances. Without preemptive knowledge, you could invest in machines far beyond your budget limitations. 


A lot of teams start out believing that the pay-per-use model saves them from extra expenses because they can maintain the various machines themselves. This couldn’t be further from the truth. And what’s worse, after their realization, they go after reserved instances and commit to durations that end up being too long. The duration of the instances you need depends on the volatility of various aspects of your environment and the shift in workload demands on different occasions. 


A plan is essential so you know what goes where and have an idea on the type of resources you need. Eventually, you’ll be able to further break it down to identify the exact machines you require.


At the core of it, it is a basic principle to be aware of what your predictable workloads are so you can equip them with reserved instances. While reserved instances force you to commit to duration, it is both cheaper and if purchased with foreknowledge, you won’t have to worry about rightsizing those instances.


Note: Try to plan your rightsizing a few weeks before the renewal of your reserved instances so you are prepared for your next commitment.


Keep up with the updated generation of instances that pops up so that you might have a cheaper or more powerful alternative to whatever you are looking for.

Choosing the right EC2 Instance

Once you’ve charted the general idea of the resources you’ll need for your initial setup, you can go deeper into the right instances you’ll need for the capacity requirements of your servers, applications, and other parts that make up your environment. 


  • Where do the instances you need for your application fall under? General purpose or compute optimized?
  • What are your security needs?
  • What about your storage specs?
  • What will be the estimated flow of traffic?


Break down all the targets you’ll need to ensure are covered to realize what particular instances you’ll need and do this across the environment.


Analyzing performance data

Analyzing the performance data of your infrastructure will let you pinpoint idle instances or instances with low CPU utilization. These rightsizing opportunities are a result of continuous monitoring. The two factors that you should keep an eye on include CPU usage and memory usage. While Amazon CloudWatch can help you monitor your resources and provide you with reports, you are forced to make the necessary rightsizing changes yourself. You may have come to the conclusion that your CPU is under a constant load of 70-80%, so you are planning to upgrade your machines but this process is entirely manual. Understanding when changes need to happen is easier than figuring out what those changes exactly are. Totalcloud can help save costs by automating the identification of rightsizing opportunities, recommending the right instances to purchase, and taking action by deploying, shutting down, or terminating the resources as per instruction. That’s a lot of birds with one stone.


AWS RDS is also benefited from the response to performance data. For RDS, all the above principles still apply but here, you should pay attention to these specific factors.

  • Average CPU utilization
  • Maximum CPU utilization
  • Minimum available RAM
  • Average memory being read and written from disk per second


Workload fluctuations

The workload of your environment can fluctuate at different times of the year. High traffic on your servers or increased requirements of memory volumes must all be responded to at the earliest. 

There are different ways you can tackle workload fluctuations. 


  • Setting an Auto scaling group will help respond accurately to meet your desired targets and react to changes. 
  • AWS Auto scaling can also be predictive and hence allows itself to be well prepared with sudden spikes.
  • Automating the rightsizing by scheduling it proactively is a viable option when you have an idea of when certain fluctuations could happen. Totalcloud lets you approach this scenario with scheduling templates.


Setting auto-scaling groups alongside your rightsizing strategies cover you in all the changing demands in machinery. It is unwise to solely rely on your ASG to respond as a lot of fluctuations and demands can be recognized with an analysis of your performance. Preparing beforehand by either modifying the instances on hand or changing their specs is a strategy that incentivizes you to always be aware of your environment.


Rightsizing is an ongoing process

Many companies adhere to forming strict plans that comply with their budget requirements but slack off on keeping up with the developments within the environment or outside.

Rightsizing can’t stop after your first major changes, aside from having a plan ready for when your reservations are expired, keeping up with monitoring activity on a constant basis will open new avenues to make adjustments that can save you money. Constant monitoring also can give you patterns and ideas that aid in predicting your workload.   


So starting out with a plan, monitoring the developments, and reworking the plan keeps you ahead of the curve against all possible demands faced during the runtime of your environment.


Helpful Tips for EC2 Rightsizing

Smart Scheduling at your fingertips

Go from simple to smart, real-time AWS resource scheduling to save cost and increase team productivity.

Learn More
More Posts

You Might Also Like

AWS Use Case Files
Launch EC2 Instances with CloudFormation
CloudFormation is the gateway to Infrastructure-as-code for AWS users. Learn how you can deploy Cloudformation templates through Totalcloud workflows and increase your customization.
June 25, 2020
Hrishikesh
AWS Use Case Files
JIRA Triggered Cloud Management
What if cloud management were as easy as raising a JIRA ticket? Almost every DevOps team uses JIRA as a standard means of issue tracking & task management. It’s a given that it would be a seamless process if you could also integrate your cloud processes with it.
June 16, 2020
Hrishikesh
AWS Use Case Files
Totalcloud Launches New Temporary Rightsizing Feature
You can't always shut down your EC2 machine outside of business hours since some machines are needed up for longer periods. Totalcloud's new downgrade feature lets you optimize your costs by letting you downgrade your machines in a fixed schedule.
June 8, 2020
Hrishikesh
AWS Use Case Files
S3 Cost Saving: Archiving Compressed S3 Data into Glacier
We've devised a new workflow to cut your archiving costs. Simplify the storage, compression, and transfer of your S3 data into S3 Glacier with 1 workflow and 8 nodes.
June 8, 2020
Hrishikesh
AWS Use Case Files
Creating a 3-tier Application With Totalcloud’s Code-Free Workflows
As part of a new request by a customer, we've developed a workflow to deploy 3-tier applications much faster. Utilising merely 3 workflows to achieve a result that would have you scripting and troubleshooting for hours. This post gives you an idea of how this workflow functions, the services being used, and how you can benefit from it.
June 2, 2020
Hrishikesh
AWS Tips & Tricks
Componentized Cloud Management: The way ahead for Cloud Automation
When something gets complex, our primary approach is to break it down — even cloud management. If you’re a part of a growing company that uses the cloud, you can see your infrastructure becoming more…
May 29, 2020
Sayonee