Explanation
Why the waste happens and who it affects.
AWS Trusted Advisor applies the same rule to SQL Server on EC2, stating that you pay for 4 vCPU licenses even if an instance has only 1 or 2 vCPUs, and AWS Prescriptive Guidance also recommends consolidating many small license-included SQL Server instances.
The pattern is common where each application, customer or environment gets its own small SQL Server instance for isolation, and in development, test and staging fleets built from the same small template. Each instance is cheap on compute, but the license floor means a fleet of 2-vCPU SQL Server instances licenses twice as many vCPUs as it runs. AWS Prescriptive Guidance shows the effect with four m6i.large SQL Server Standard servers: consolidating them onto one m6i.2xlarge keeps the same total vCPUs and memory but halves the vCPUs to license, from 16 to 8 (using Microsoft's public Standard pricing, $31,560 versus $15,780).
Billing model
The pricing dimensions that drive this cost.
- Four-core license minimum
- SQL Server core licenses are sold in two-core packs with a minimum of four cores per server, so an instance with fewer vCPUs is licensed as four
- Bring your own license
- Each small instance consumes four core licenses from the customer's SQL Server license pool
- License-included instances
- The SQL Server license is part of the EC2 hourly rate for the SQL Server AMI, and AWS guidance still recommends consolidating many small license-included instances
How to detect
4 checks to find it in your estate.
- Review the Trusted Advisor cost optimization check Amazon EC2 instances consolidation for Microsoft SQL Server (check ID Qsdfp3A4L2), which turns yellow for any instance running SQL Server with fewer than 4 vCPUs and reports the vCPU count, minimum vCPU and SQL Server edition
- Inventory SQL Server instances by vCPU count, edition and licensing model, and count how many have 1 or 2 vCPUs
- Collect CPU, memory, network and storage IOPS and throughput metrics over a long period for the small instances, including when their peaks occur, to see which ones could share a server
- Group small instances by environment, edition and compliance boundary to find realistic consolidation sets, such as non-production databases
How to fix
5 ways to remove the waste.
- Consolidate several small SQL Server workloads onto one instance with at least four vCPUs, either as multiple databases in one SQL Server instance or as multiple named SQL Server instances on one EC2 instance
- When stacking named instances, give each a unique name and port, run the SQL Server Browser service, and set max server memory for each so their total leaves memory for the operating system
- Migrate databases with native backup and restore or AWS DMS, then retire the small instances
- Prefer consolidating low-usage and non-production databases; AWS does not recommend putting large production databases on a single server
- For databases that are too small to justify SQL Server licensing at all, evaluate a free edition (Express within its limits, or Developer for non-production) or another engine
Documentation
Vendor references for pricing and configuration.