RDS vs EC2 for SQL Server

Here’s where the SQL Server phase of the course begins. The first decision on any SQL Server project is RDS vs EC2 SQL Server, meaning either AWS runs the database engine for you or you run SQL Server yourself on a Windows server. Get it wrong and you’ll spend years fighting RDS restrictions, or doing patching and failovers you never needed to do.

You’ll list the SQL Server versions RDS offers, check which instance sizes each edition supports, compare real hourly prices using the AWS Price List API, and save a readiness script that finds blockers on an existing server. Then you’ll fix two mistakes people tend to make while comparing.

TimeYou needBy the end you can
40 minutesYou need your laptop signed in as saat-admin, and if you can, access to an existing SQL Server plus the sqlcmd tool (winget install Microsoft.Sqlcmd). It costs nothing, because the Price List API and describe calls are free of charge.Explain what RDS manages and what it restricts, and compare RDS, RDS Custom and EC2. Check versions and orderable instance classes, price both options with the Price List API, and find migration blockers with T-SQL.

What it is, in one line

RDS vs EC2 SQL Server is the choice between a managed database service, where AWS runs the engine, and a Windows server on EC2 where you run SQL Server yourself.

In Simple Words

A serviced apartment or your own flat

A serviced apartment comes with cleaning, repairs and security, but you can’t knock down a wall or change the plumbing, and it costs a bit more each month. That’s RDS.

In your own flat you can change whatever you like, but when the geyser breaks at midnight it’s your problem, and that’s SQL Server on EC2.

Somewhere in between is the serviced flat that lets you bring a few of your own fittings, which is RDS Custom.

Engineer's View

What RDS for SQL Server gives and takes

RDS runs SQL Server 2016, 2017, 2019, 2022 and 2025 in Express, Web, Standard and Enterprise editions. AWS takes care of OS and engine patching, automated backups with point-in-time restore, Multi-AZ failover, storage scaling and monitoring. The master user gets db_owner on user databases and broad server-level rights, but not sysadmin, and there’s no OS or RDP access.

Things RDS doesn’t support include log shipping, replication, FILESTREAM and FileTables, maintenance plans, xp_cmdshell, server-level triggers, Service Broker endpoints and the TRUSTWORTHY property. CLR isn’t supported on 2017 and later, SSAS isn’t available on 2022 and SSIS isn’t on 2025. An instance holds up to 30 databases (micro to large) or 100 (xlarge and up, Single-AZ). Since June 2026 gp3 storage goes up to 64 TiB, and io2 goes to 64 TiB and 256,000 IOPS.

SQL Server on EC2 gives you sysadmin and full control (Always On AGs, log shipping, any feature you want), using license-included Windows+SQL AMIs or your own licences. RDS Custom for SQL Server sits in the middle, with AWS automation plus OS access for apps that need it. Express is capped at 10 GB per database, so keep it for small or test workloads.

How it works, step by step

In the end it comes down to who does which job:

RDS vs EC2 SQL Server: who does patching, backups and failover

1List what you need

Look at the features, how many databases there are and how big, the version and edition, and who needs which permissions.

2Look for blockers

If anything on the unsupported list shows up, RDS is out for that workload unless the app can be changed.

3Compare total cost, not hourly price

RDS costs more per hour than the same size on EC2, but it includes work your team would otherwise be doing. Go through this checklist:

RDS vs EC2 SQL Server decision checklist: features, size, operations, cost

Most companies end up with both, RDS for the many ordinary application databases and EC2 for the few that need sysadmin features, and that’s the setup this phase teaches.

✅ Checkpoint: You can list what RDS manages, name five features RDS doesn’t support and say when RDS Custom or EC2 is the better choice.

Hands-on lab: RDS vs EC2 SQL Server, checked and priced

Before you run any command, double-check it

Read every command twice before you press Enter. Check the target: the system or account, the IDs, the names and the sizes. These commands are for learning and were tested in our lab, not on your system. At work, run the read-only list commands first, follow your change process, make sure a backup exists, and ask a second person to check anything that changes or deletes data. You run them at your own risk.

Sign in:

cd C:\aws-lab
aws login --profile saat-admin
$env:AWS_PROFILE = 'saat-admin'

1See which SQL Server versions RDS offers

Paste this whole block:

foreach ($e in 'sqlserver-ex', 'sqlserver-web', 'sqlserver-se', 'sqlserver-ee') {
  $latest = aws rds describe-db-engine-versions --engine $e --query "DBEngineVersions[-1].EngineVersion" --output text
  "{0,-14} latest {1}" -f $e, $latest
}
aws rds describe-db-engine-versions --engine sqlserver-se --query "DBEngineVersions[-3:].EngineVersion" --output text

You should see something like this:

sqlserver-ex   latest 17.00.4075.5.v1
sqlserver-web  latest 17.00.4075.5.v1
sqlserver-se   latest 17.00.4075.5.v1
sqlserver-ee   latest 17.00.4075.5.v1
16.00.4265.3.v1        17.00.4065.4.v1 17.00.4075.5.v1

Major version 16 is SQL Server 2022 and 17 is SQL Server 2025, and the numbers after that are the cumulative update. RDS offers several, so you can match what you run today and upgrade later on (Lesson 53).

2Check which sizes each edition supports

Paste this whole block:

$v22 = aws rds describe-db-engine-versions --engine sqlserver-ex --query "DBEngineVersions[?starts_with(EngineVersion, '16.00')] | [-1].EngineVersion" --output text
$exClasses = aws rds describe-orderable-db-instance-options --engine sqlserver-ex --engine-version $v22 --query "OrderableDBInstanceOptions[].DBInstanceClass" --output text
($exClasses -split '\s+' | Sort-Object -Unique) -join ' '
$seCount = aws rds describe-orderable-db-instance-options --engine sqlserver-se --engine-version ($v22) --query "length(OrderableDBInstanceOptions[?starts_with(DBInstanceClass, 'db.m6i')])"
"Standard edition db.m6i options: $seCount"

You should see something like this:

db.t3.large db.t3.medium db.t3.micro db.t3.small db.t3.xlarge
Standard edition db.m6i options: 18

Express only runs on small classes, which is why it’s fine for labs and tiny apps but not for production. For the rest of this phase you’ll use Express on db.t3.micro to keep costs down.

3Compare real prices with the Price List API

Paste this whole block. It defines a helper and prices the same size on RDS and on EC2 in Mumbai:

function Get-OnDemandPrice([string]$Service, [string[]]$Filters) {
  $f = $Filters | ForEach-Object { $k, $val = $_ -split '=', 2; "Type=TERM_MATCH,Field=$k,Value=$val" }
  $list = aws pricing get-products --region us-east-1 --service-code $Service --filters $f --max-items 1 --query PriceList --output json | ConvertFrom-Json
  if (-not $list) { return $null }
  $p = $list[0] | ConvertFrom-Json
  $od = @($p.terms.OnDemand.PSObject.Properties.Value)[0]
  [double](@($od.priceDimensions.PSObject.Properties.Value)[0].pricePerUnit.USD)
}
$rds = Get-OnDemandPrice AmazonRDS @('regionCode=ap-south-1', 'databaseEngine=SQL Server', 'databaseEdition=Standard', 'instanceType=db.m6i.xlarge', 'deploymentOption=Single-AZ', 'licenseModel=License included')
$ec2 = Get-OnDemandPrice AmazonEC2 @('regionCode=ap-south-1', 'instanceType=m6i.xlarge', 'operatingSystem=Windows', 'preInstalledSw=SQL Std', 'tenancy=Shared', 'capacitystatus=Used', 'licenseModel=No License required')
"RDS SQL Std db.m6i.xlarge:  {0:N3} USD/h" -f $rds
"EC2 Win+SQL Std m6i.xlarge: {0:N3} USD/h" -f $ec2
"Difference per month: {0:N0} USD" -f (($rds - $ec2) * 730)

You should see something like this (prices change, so yours may differ):

RDS SQL Std db.m6i.xlarge:  1.725 USD/h
EC2 Win+SQL Std m6i.xlarge: 1.252 USD/h
Difference per month: 345 USD

RDS does cost more per hour. What you really need to ask is whether roughly USD 345 a month is less than what it costs your team to patch, back up, monitor and fail over that server, plus the outage the day somebody forgets. For one critical database, it usually is.

With Multi-AZ, both sides roughly double.

RDS vs EC2 SQL Server lab output: engine versions and hourly price comparison
Engine versions and the price comparison. Something like this.

4Save a readiness check for existing servers

Paste this whole block. If you have a SQL Server, run the script now, and if not, keep it for Lesson 42:

@'
-- Check-RdsReadiness.sql: run on the source SQL Server
SET NOCOUNT ON;
SELECT CAST(SERVERPROPERTY('ProductVersion') AS varchar(20)) AS version, CAST(SERVERPROPERTY('Edition') AS varchar(40)) AS edition;
SELECT COUNT(*) AS user_databases FROM sys.databases WHERE database_id > 4;
SELECT DB_NAME(database_id) AS db, CAST(SUM(size) * 8.0 / 1024 / 1024 AS decimal(10,2)) AS size_gb
  FROM sys.master_files WHERE database_id > 4 GROUP BY database_id ORDER BY size_gb DESC;
SELECT name, value_in_use FROM sys.configurations WHERE name IN ('clr enabled', 'filestream access level', 'xp_cmdshell');
SELECT (SELECT COUNT(*) FROM sys.servers WHERE is_linked = 1) AS linked_servers,
       (SELECT COUNT(*) FROM sys.server_triggers) AS server_triggers,
       (SELECT COUNT(*) FROM sys.databases WHERE is_published = 1 OR is_merge_published = 1 OR is_distributor = 1) AS replication_dbs,
       (SELECT COUNT(*) FROM msdb.dbo.log_shipping_primary_databases) AS log_shipping_dbs,
       (SELECT COUNT(*) FROM msdb.dbo.sysmaintplan_plans) AS maintenance_plans;
'@ | Set-Content C:\aws-lab\Check-RdsReadiness.sql
# Example on a server you can reach with Windows login:
# sqlcmd -S YOURSERVER -E -i C:\aws-lab\Check-RdsReadiness.sql -W

On a typical older application server you might get something like this:

version  edition
13.0.6435.1 Standard Edition (64-bit)
user_databases
7
name                    value_in_use
clr enabled             1
filestream access level 0
xp_cmdshell             0
linked_servers server_triggers replication_dbs log_shipping_dbs maintenance_plans
2              0               0               1                3

In this example CLR is on (check whether any assemblies are used, because RDS 2017+ won’t run them), one database uses log shipping (swap that for RDS backups or DMS), and the maintenance plans have to become SQL Agent jobs or RDS features. Each line is a work item, and none of them automatically means you stay on EC2.

SSMS results of migration readiness checks on the source SQL Server 2016 instance
The readiness checks in SSMS: each row is a work item for the move, from CLR to log shipping.

✅ Checkpoint: You listed the RDS SQL Server versions, saw which classes Express supports, priced RDS against EC2 for the same size and saved Check-RdsReadiness.sql.

Break It, Then Fix It

Here are two mistakes that either make the comparison wrong or slow the project down.

1Break it: guess a pricing attribute value

Ask for “Standard Edition” rather than the exact value:

$bad = Get-OnDemandPrice AmazonRDS @('regionCode=ap-south-1', 'databaseEngine=SQL Server', 'databaseEdition=Standard Edition', 'instanceType=db.m6i.xlarge', 'deploymentOption=Single-AZ', 'licenseModel=License included')
"price: [$bad]"

You should see this:

price: []

There’s no error, you simply get nothing back, because the Price List API only matches exact attribute values. A spreadsheet built like this quietly shows zero for RDS. Fix: ask the API which values exist:

aws pricing get-attribute-values --region us-east-1 --service-code AmazonRDS --attribute-name databaseEdition --query "AttributeValues[].Value" --output text

You should see something like this:

Developer       Enterprise      Express Standard        Web

2Break it: an edition on a size it doesn’t support

Try creating an Express instance on a large class. It fails before anything gets created:

aws rds create-db-instance --db-instance-identifier saat-sql-test --engine sqlserver-ex --engine-version $v22 --db-instance-class db.r6i.8xlarge --license-model license-included --allocated-storage 20 --master-username saatadmin --manage-master-user-password

You’ll get this error:

An error occurred (InvalidParameterCombination) when calling the CreateDBInstance operation: RDS does not support creating a DB instance with the following combination: DBInstanceClass=db.r6i.8xlarge, Engine=sqlserver-ex, EngineVersion=16.00.4265.3.v1, LicenseModel=license-included. For supported combinations of instance class and database engine version, see the documentation.
Selection mistakes: wrong pricing attribute value and invalid RDS instance class combination
Both mistakes and their fixes. Something like this.

Every combination of edition, version and class has to be orderable in that Region, and for the same reason infrastructure code that worked last year can break after a version change. Fix: check before you build, the way you did in step 2:

aws rds describe-orderable-db-instance-options --engine sqlserver-ex --engine-version $v22 --db-instance-class db.t3.micro --query "length(OrderableDBInstanceOptions)"

Any number above zero means the combination exists:

2

Nothing was created in this lesson, so there’s nothing to clean up. Hang on to Check-RdsReadiness.sql.

✅ Checkpoint: You found an exact pricing attribute value with get-attribute-values and an orderable combination with describe-orderable-db-instance-options.

This happened at work

The migration that hit a wall in week six

A retail company planned to move 22 SQL Server databases to RDS in eight weeks. Six weeks in, the team got to the warehouse system and discovered it used CLR assemblies for barcode processing, along with a linked server to an old Oracle box running an unusual driver.

CLR isn’t supported on RDS for SQL Server 2017 and later, and the app team couldn’t rewrite the code before the data centre contract ran out. So they built an EC2 server for that one system in a hurry, without the standards the RDS databases had, and spent months fighting gaps in backup and patching.

Now the company runs a readiness script like this one against every source server in week one, and decides between RDS, RDS Custom and EC2 for each database before anyone writes a migration plan.

Common mistakes and troubleshooting

MistakeWhat happensWhat to do
Choosing RDS without checking featuresBlockers found mid-migrationRun a readiness check on every source server first
Comparing hourly prices onlyEC2 looks cheaper than it isInclude patching, backups, HA and on-call time
Express for production10 GB per database, small classes onlyStandard or Enterprise for production
Guessing pricing attribute valuesEmpty results, wrong spreadsheetsUse get-attribute-values
Assuming every class is availableInvalidParameterCombination at build timeCheck orderable options per edition and version
Forgetting the 30 or 100 database limitConsolidation plans failPlan instance sizes around database counts

Interview questions

Click a question to open it. Each one is phrased the way an interviewer would ask it, and underneath you’ll find why they ask it and one way you could answer in your own words.

Fresher level

1. If your company moves a SQL Server database to RDS, what work does AWS take off your plate?

Why they ask this: They want to know you understand what a managed database means in practice, and whether you could explain the value of RDS to a team.

How you might answer: RDS takes care of OS and engine patching, automated backups with point-in-time restore, Multi-AZ failover, storage scaling, monitoring and the hardware underneath.

That means the DBA team spends more of its time on queries and design and less on keeping servers alive.

2. A DBA asks you for sysadmin rights on the new RDS SQL Server instance. What would you tell them?

Why they ask this: They’re checking you know the limits of RDS, because a lot of migration problems start with someone assuming they’d have full control.

How you might answer: I’d explain that RDS for SQL Server doesn’t offer sysadmin, and there’s no OS access either. The master user gets db_owner on user databases and a selected set of server permissions.

If they truly need sysadmin, then we’d be talking about SQL Server on EC2 instead.

3. Before moving a SQL Server database to RDS, which features would you check, because RDS doesn’t support them?

Why they ask this: They want to see you check for blockers before a migration, since finding an unsupported feature late can stop a project.

How you might answer: I’d check whether the database uses log shipping, replication, FILESTREAM, maintenance plans, xp_cmdshell or server-level triggers, because RDS doesn’t support any of them, and I’d look for CLR on SQL Server 2017 and later too.

If any of them turn up, I’d raise it with the app team early.

2–5 years experience

4. When would you choose to run SQL Server on EC2 instead of RDS?

Why they ask this: They want clear decision making, and to hear that you’d pick EC2 for real reasons and not out of habit.

How you might answer: I’d go with EC2 when we need sysadmin or OS access, or features RDS doesn’t support, like CLR on newer versions, log shipping or SSAS on 2022. Custom high availability, such as Always On across Regions, is another reason.

Licensing can also settle it, for example when we’re bringing our own licences to dedicated hosts.

5. Can you explain what RDS Custom for SQL Server is, and when it helps?

Why they ask this: They’re checking you know there’s a middle option between RDS and EC2, which shows you’re aware of the full range of choices.

How you might answer: RDS Custom is a managed option that still automates backups and other tasks the way RDS does, but also gives you OS and database access. I’d use it for an app that needs some customization RDS won’t allow, when we’d still like AWS to handle the routine work.

6. Your manager asks if RDS or EC2 is cheaper for SQL Server. How would you compare them fairly?

Why they ask this: They want to see you look at the full cost and not only the hourly price, because people’s time is often the biggest hidden cost.

How you might answer: On both sides I’d include the licence, compute, storage, Multi-AZ or Availability Group secondaries and backup storage. Then on the EC2 side I’d add the people time for patching, backups, monitoring and failover testing.

That’s the only fair comparison, because EC2 often looks cheaper until you count that work.

Senior level

7. You’re asked to plan the move of 60 SQL Server databases to AWS. How would you design the database platform?

Why they ask this: They want architecture and planning at scale, and whether you match each database to the right option instead of forcing one answer on all of them.

How you might answer: I’d start with a readiness assessment for every database. Most of them would go to RDS Multi-AZ, consolidated by size and tier within the database limits, and the handful with blockers would go to EC2 with Always On.

I’d use Managed AD for Windows authentication, standard parameter and option groups, and AWS Backup with cross-Region copies, with DMS for a low-downtime migration.

8. A team insists they need SQL Server on EC2 “for performance”. How would you respond?

Why they ask this: They want to see your judgement and how you deal with pushback, and whether you decide with data rather than opinions.

How you might answer: I’d ask what they need: IOPS and throughput, memory size, or a particular feature. RDS with io2 and gp3 storage goes very high these days, so performance on its own isn’t always a reason.

I’d benchmark both with the real workload and only choose EC2 if there’s a concrete gap, because it brings a lot of extra operational work.

Quick quiz

Q1. Which feature does RDS for SQL Server 2022 not support?

  1. Automated backups
  2. Log shipping
  3. Multi-AZ
  4. TDE
Show answer

B — Log shipping isn’t supported on RDS.

Q2. Which role does the RDS master user not get?

  1. db_owner on user databases
  2. sysadmin
  3. CREATE LOGIN
  4. View server state
Show answer

B — RDS never gives sysadmin.

Q3. Why did the Price List query return nothing?

  1. Wrong Region
  2. The attribute value was not exact
  3. No permissions
  4. The API was down
Show answer

B — Use get-attribute-values to find exact values.

Q4. Why is Express a poor choice for production?

  1. It has no backups
  2. 10 GB per database and small classes only
  3. It can’t use SSL
  4. It isn’t supported on RDS
Show answer

B — Express limits are tight.

Q5. What sits between RDS and EC2 for SQL Server?

  1. Aurora
  2. RDS Custom for SQL Server
  3. Lambda
  4. DynamoDB
Show answer

B — RDS Custom gives automation plus OS access.

Quick recap

  • RDS runs SQL Server for you; EC2 gives full control and full responsibility.
  • RDS has no sysadmin and no log shipping, replication, FILESTREAM or CLR on 2017+.
  • Check orderable classes per edition and version before building.
  • Compare total cost, including your team’s time, not just hourly prices.
  • Run a readiness check on source servers before planning a migration.

Next lesson

Lesson 41: SQL Server licensing on AWS → Next you’ll compare License Included with bring-your-own-licence options and see how each one changes your instance choices and cost.

Further reading: RDS vs EC2 SQL Server

Want to go deeper into RDS vs EC2 SQL Server? Read Amazon RDS for Microsoft SQL Server and Features not supported and features with limited support. You can also see the full plan for this course on the AWS Cloud Administration course page.

Scroll to Top

This website uses cookies

We use a few cookies to keep this site working. If you allow it, we also use Google Analytics to count visits so we can improve our lessons. You can accept all, deny the optional ones, or choose what to allow.