A common way to save costs is by purchasing Reserved Instances (RIs). In this blog post, I will explain, using a practical example, how and to what extent costs can be saved with these RIs.
What is a Reserved Instance?
A Reserved Instance (RI) is a commercial agreement in which a company commits to acquiring certain resources, such as Virtual Machines (VMs), for a specified period (e.g., 1, 3, or 5 years). In return for this commitment, they receive significant discounts compared to pay-as-you-go pricing. Payment can be made monthly or in advance for the full contract period, even if the guaranteed VMs are not fully utilized. While this may seem inflexible at first glance, the allocation of an RI is automatically managed, and discounts are automatically applied to other eligible VMs when changes occur.
It is important to note that, contrary to common misconceptions, RIs do not guarantee VM availability (although this is possible with other Azure products). It is purely a financial arrangement.
Practical Example:
Let’s examine a practical example in which we conducted a QuickScan for a customer who migrated an application to Azure. This application includes both a production and a staging environment, each with 5 VMs. The production environment runs 24×7, while the staging environment is active for 7×12 hours. The outcome of the quick scan indicated that significant cost savings were possible, approximately 60% for the production environment and 16% for the staging environment, through the use of RIs.
Since a QuickScan often does not provide an optimal solution, at the customer’s request, we conducted a more in-depth analysis. Together with the application administrator, we assessed the usage and size of the VMs. Our analysis revealed limited CPU and memory usage. We then tested whether the application continued to run smoothly on smaller VMs of the same family, which worked well. This resulted in a reduction in the size of many VMs in each environment, leading to a corresponding cost reduction.
We also analyzed the usage of the staging environment and found that it was used by a very limited number of users. We configured the environment to allow users to start and stop it manually, and it is also automatically shut down at 7:00 PM. In practice, this environment is now used for a maximum of 12 hours per week.
Finally, we purchased RIs for all VMs in the production environment for a 3-year period. This resulted in an additional savings of 60% on top of the savings already achieved through resizing.
Outcome
In total, we achieved an impressive cost savings of 85% for the VMs used in Azure for this application. As mentioned in my previous blog post, it is important to note that these savings should be considered in relation to the total Azure costs for this application, which include not only compute (VMs) but also storage, a SQL database, backup, network connectivity, and security components. By adjusting the VMs, a total savings of over 30% was realized.
The chart above depicts the percentage savings at both the VM level and the total cloud costs for this application.