Let’s accept one fact that none wants to spend money on something which is not giving the right value. While AWS provides the tremendous amount of configurations to be able to manage and control your infrastructure and costs, many times we end up realizing that we could have saved some additional cost for our company and customers.
Organizations are moving to the cloud and this movement seems to be inevitable. The beautiful about this is that it suits the startups as well as the large enterprises. The investment in increasing capital expenditure is gradually reducing and people are finding is relevant to have access to more scalable and secure infrastructure, even though it may mean an increase in the monthly operating expense.
As part of this article, I will talk about the 5-key ideas you shall be aware of to be able to manage your AWS budget better.
Common mistakes the financially ignorant team makes
Old habits die hard
Most of us in the transition phase was either abstracted from the access to the server or had the restricted access to on-premise infrastructure, where the main goal was to ensure that there is maximum up-time. However, this focus on keeping the server up all the time created a bad habit of not being conscious of when an instance shall be put down.
In a scalable cloud environment, this is a common mistake that the developers commit. They leave the instances and virtual machines running even when they are not supposed to be used, which leads to increase in the number of hours/minutes of CPU usage and network charges. Specifically, when you have development, test and demo instances on the cloud, you can definitely predict its usage and put this down. However, due to the bad habit, the developers often leave it running.
Lack of regular audit
Many times we do subscribe or configure a given service with a concrete business goal in perspective. Sometimes these goals are short or mid-term goals and we keep running this even when it may no longer be needed.
This problem can often occur even when you are turning the services on / off based on the overall usage (e.g. even when you can keep the servers down on weekend or holidays). I strongly believe that this happens because of lack of proper accountability at the end of the sponsor.
When a volume is no longer needed (e.g. suppose it gets orphaned) or old snapshot is not used or when a service is not desired (e.g. you may be doing some experiment) then such instances shall be identified during the regular audit of the resources.
The more the better attitude
It is kind of old habit, but there is a bit more to it than just the habit part. Vertical scaling was always a challenge and hence we often used to do the detailed hardware sizing by keeping then 3-5 years processing and storage need in perspective. That habit still lead some of us to chose a higher configuration, when a lower configuration in the initial stage or during the off-peak seasons will be just good enough.
How is Amazon helping you plan better?
While you do need to be conscious of the cloud usage and minimize your wastage, AWS does provide you a number of ways to keep an eye on this aspect of your business.
They have following products/features, which enables you to manage your costs better:
- Free Tier
- Reserved, Spot Instances
- Using the Calculator
- Cloud Trail
- Billing Alarms
You can try some AWS services free of charge, within certain usage limits. AWS calls this the AWS Free Tier. The free tier is designed to give you hands-on experience with a range of AWS services at no charge. For example, you can explore AWS as a platform for your business by setting up a test website with a server, alarms, and database.
When you create an AWS account, you are automatically signed up for the free tier for 12 months. Your free tier eligibility expires at the end of the 12-month period. When your free tier expires, AWS starts charging the regular rates for any AWS services and resources that you are using.
To avoid charges while on the free tier, you must keep your usage below the free tier limits. You are charged for any usage that exceeds the limits. To help you stay within the limits, you can track your free tier usage and set a billing alarm to notify you if you start incurring charges.
If you don’t use the full benefits provided by the free tier in a given month, the benefits don’t roll over to the next month. To maximize your free tier benefits, be sure to spend time with AWS each month, trying out the services that you are curious about.
Reserved, Spot Instances
Reserved Instances provide you with a significant discount compared to On-Demand Instance pricing. Reserved Instances are not physical instances, but rather a billing discount applied to the use of On-Demand Instances in your account. These On-Demand Instances must match certain attributes in order to benefit from the billing discount.
If you have a running On-Demand Instance (T2) in your account, for which you’re currently paying On-Demand rates. You purchase a Reserved Instance that matches the attributes of your running instance, and the billing benefit is immediately applied.
Spot Instances enable you to bid on unused EC2 instances, which can lower your Amazon EC2 costs significantly. The hourly price for a Spot Instance (of each instance type in each Availability Zone) is set by Amazon EC2, and fluctuates depending on the supply of and demand for Spot Instances. Your Spot Instance runs whenever your bid exceeds the current market price.
Spot Instances are a cost-effective choice if you can be flexible about when your applications run and if your applications can be interrupted. For example, Spot Instances are well-suited for data analysis, batch jobs, background processing, and optional tasks.
Using the Calculator
You can use various calculators provided by AWS to be able to estimate the net cost of the infrastructure that you are subscribing. Specifically, when you have budget cap available for your experimental projects, this calculator is very helpful.
Billing Alarms :
Even if you’re careful to stay within the free tier, it’s a good idea to create a billing alarm to notify you if you exceed the limits of the free tier. Billing alarms can help to protect you against unknowingly accruing charges if you inadvertently use a service outside of the free tier or if traffic exceeds your expectations.
After you complete this procedure, you’ll receive an email as soon as your account’s usage exceeds the free tier limits. At that point, you can decide whether to terminate the AWS resources that have exceeded the free tier limits, or keep them running and be billed at the standard AWS rates.
If your AWS account is not a free tier account then you can monitor your AWS costs by using CloudWatch. With CloudWatch, you can create billing alerts that notify you when your usage of your services exceeds thresholds that you define. You specify these threshold amounts when you create the billing alerts. When your usage exceeds these amounts, AWS sends you an email notification. You can also sign up to receive notifications when AWS prices change.
Amazon Glacier is an extremely low-cost storage service that provides durable storage with security features for data archiving and backup. With Amazon Glacier, customers can store their data cost-effectively for months, years, or even decades.
Amazon Glacier enables customers to offload the administrative burdens of operating and scaling storage to AWS, so they don’t have to worry about capacity planning, hardware provisioning, data replication, hardware failure detection, and recovery, or time-consuming hardware migrations.
Amazon Glacier is a great storage choice when low storage cost is paramount, your data is rarely retrieved, and retrieval latency of several hours is acceptable. If your application requires fast or frequent access to your data, consider using Amazon S3
AWS CloudTrail is an AWS service that helps you enable governance, compliance, and operational and risk auditing of your AWS account. Actions taken by a user, role, or an AWS service are recorded as events in CloudTrail. Events include actions taken in the AWS Management Console, AWS Command Line Interface, and AWS SDKs and APIs.
Visibility into your AWS account activity is a key aspect of security and operational best practices. You can use CloudTrail to view, search, download, archive, analyze, and respond to account activity across your AWS infrastructure. You can identify who or what took which action, what resources were acted upon, when the event occurred, and other details to help you analyze and respond to activity in your AWS account.
You can integrate CloudTrail into applications using the API, automate trail creation for your organization, check the status of trails you create, and control how users view CloudTrail events.
CloudTrail is enabled on your AWS account when you create it. When activity occurs in your AWS account, that activity is recorded in a CloudTrail event. You can easily view events in the CloudTrail console by going to Event history.
It does hurt to spend money for which you don’t get value. As part of this article, I have tried to put my findings on ways to control and manage costs of AWS infrastructure. I hope this helps you in saving few dollars without compromising on your need.
At Walking Tree, we have been a great admirer of the infrastructure support that AWS provides. Specifically when it makes the same infrastructure available for an individual as well as a large enterprise then it opens the door for various possibilities. We do understand that using the AWS correctly can enable you to derive the better value for your money. Please do connect with us with specific questions and we will be happy to assist!