The Power Of Cleaning Up And Right-Sizing

How cleaning up and right-sizing resources can lead to enormous monthly cost savings (read the case study)

Read on Beehiiv | Oct 20th, 2024

Welcome to The Cloud Economist!

Last week I talked about various ways to make Amazon DynamoDB cheaper, I shared some tips including using TTLs, proper primary key design, eliminating scans, reducing transactions, and more.

I also briefly talked about the single table design and how it can help you further reduce your monthly DynamoDB costs.

If you missed that you can read it here. (it’s loaded with solid tips).

In the question of the week, I asked: “How can TTLs save you a significant amount of money in DynamoDB?“

Answer

TTLs are an automated way to delete stale data that you aren’t using but that adds storage costs to your database.

By having DynamODB regularly delete data after the expiration date you set, you aren’t charged for the delete operation even at scale.

I recently wrote a fascinating story about how Medium encountered a multi-thousand-dollar problem that could have easily been averted by using TTLs.

This week I want to show you the effectiveness of cleaning up unused resources and right-sizing the rest - especially idle resources.

Here are the best articles I’ve found on cloud cost savings this week, summarized.

Monthly cost breakdown for Eran’s company

Article 1

In this case study, the company Eran works for brought down their monthly AWS costs from $10,000 to $1,500.

Here’s how they achieved this:

1. Clean Up ECR Images

• Problem: Old Docker images were piling up in ECR.

• Solution: Applied lifecycle policies to delete images older than 30 days.

• Savings: $387/month

2. Optimize ECS Fargate Services

• Problem: Over-provisioned Fargate tasks.

• Solution: Right-sized tasks and used Fargate Spot instances.

• Savings: $2,700/month

3. Manage S3 Bucket Storage

• Problem: Unused and outdated S3 data accumulated without lifecycle rules.

• Solution: Set up data expiration policies.

• Savings: $270/month

4. Switch VPN to Secure SSH Tunnel

• Problem: High operational costs from VPNs.

• Solution: Replaced VPNs with Secure SSH Tunnels.

• Savings: $357/month

5. Right-Size RDS and DocumentDB Instances

• Problem: Over-provisioned RDS and DocumentDB instances.

• Solution: Right-sized based on actual usage.

• Savings: $1,200/month

6. Purchase ECS Savings Plans

• Problem: No savings plans, higher on-demand pricing.

• Solution: Bought ECS savings plans.

• Savings: $180/month

7. Consolidate Load Balancers

• Problem: Multiple load balancers increased costs.

• Solution: Switched to a single ALB.

• Savings: $510/month

8. Remove Redundant IPv4 Addresses

• Problem: Unused IPv4 addresses were still being billed.

• Solution: Audited and removed unused addresses.

• Savings: $480/month

9. Remove a Redundant Environment

• Problem: An unused alpha environment added extra costs.

• Solution: Decommissioned the environment.

• Savings: $1,500/month

10. Right-Size Remaining Resources

• Problem: Resources like ElasticCache and Redshift were over-provisioned.

• Solution: Right-sized based on usage metrics.

• Savings: $800/month

Their total savings was $8,384

The recurring theme is cleaning up and right-sizing resources.

There is enormous value and cost-saving opportunities in auditing resources, and constant optimization of your infrastructure.

One Tip on Cloud Cost Savings

With AWS Trusted Advisor and Cost Explorer, you can set automated budget alerts and recommendations to help catch cost inefficiencies early.

Automating this process ensures consistent savings every month without manual intervention, catching spikes in costs before they become significant.

Most of the cost savings opportunities in the article above can be found with Trusted Advisor.

This Week’s Question

How can AWS Trusted Advisor’s “Idle Load Balancers” check help reduce costs?

Check back here next week for the answer!

Until next week.

The Cloud Economist