Migrating Your SQL Database to the Cloud: AWS vs Azure
When migrating your SQL databases to the cloud you need to make your choice carefully. Migration is time-consuming and can be costly, in terms of resources, support, and downtime. You don’t want to lose productivity or revenue when migrating to a service, only to find there was a better option available.
In this article, you’ll learn how AWS services compare to Azure and why migrating your databases to Azure can provide greater returns. In particular, you’ll learn how Azure’s migration solutions, flexible deployments, and licensing support can provide better value for organizations seeking an enterprise-grade solution.
Migrating SQL to AWS
When migrating to AWS, you can replatform your database to Amazon Relational Database Service (RDS). RDS is a managed service that supports several database engines, including, Amazon Aurora, PostgreSQL, Oracle, MariaDB, MySQL, and Microsoft SQL Server. It takes care of infrastructure maintenance for you in exchange for flexibility and granular control.
Within RDS, there are two architecture types. With all engines except Aurora, your database is hosted on a storage volume and the engine is hosted on a compute instance (similar to EC2 and EBS). This enables you to provision storage and compute resources independently. However, to scale, your only option is to create read replicas and you cannot scale automatically.
Aurora is a proprietary database created by AWS and is compatible with MySQL and PostgreSQL databases. In Aurora, storage scales with compute resources, eliminating the need to provision resources separately. This option allows you to scale up to 15 read-replicas.
AWS Database Migration Service (DMS)
To make migration easier, Amazon offers AWS DMS. This service enables you to perform online, homogeneous (i.e. SQL Server to SQL Server) or heterogeneous (i.e. SQL Server to PostgreSQL) migrations.
With DMS, you can transfer a static copy of your database or a database with logged changes. You can also use the service to supplement a manual migration by only replicating changes that occur after your database copy is made.
To use this service, you select your compute instance type and provision storage for logs and change caching. Once your resources are defined you can specify the type of migration you want (full copy, fully copy with changes, or changes only) via the creation of a replication task which specifies your database endpoints, credentials, etc.
Unfortunately, this service does not support automatic migrations. It also does not support the conversion of schema if you are doing a heterogeneous migration.
Migrating SQL to Azure
When migrating to Azure, you can transfer your data to Azure SQL Database. It is a managed Platform as a Service (PaaS) that supports SQL Server workloads. With this service you are responsible for managing your data, access, and any applications. However, Microsoft takes care of the infrastructure and database engine maintenance.
When using SQL Database, you have three deployment options — Managed Instance, Single, or Elastic Pool. Managed Instances are clusters of databases sharing an engine and Elastic Pool is a collection of single databases with shared resources.
Single is a single, isolated database. With Single, you can customize your provisioning by specifying resource amounts, specifying performance, or using serverless to scale automatically. The other two options dynamically scale.
When using SQL Database you have the ability to create hybrid databases. You can create a fully hybrid system with a replica in the cloud through Azure SQL Data Sync, which continuously syncs data. You can also create a partial hybrid through the addition of Stretch Database, which is a service that transparently migrates cold data from on-premises servers to the cloud.
Azure Database Migration Service
To assist with migrating your data, Microsoft provides the Azure Database Migration Service. This service supports SQL Server, PostgreSQL, MySQL, and MongoDB migrations and you can use it to transfer your data to SQL Database, Database for PostgreSQL, MySQL, and Cosmos DB.
Database Migration Service supports homogeneous and heterogeneous migrations, both on and offline, with change replication. It can also move data, schema, and objects. It is resilient and self-healing, enabling it to automatically resume following an interruption with no data loss or corruption. Additionally, unlike AWS DMS, this service allows automation via PowerShell commandlets.
Included in the service is a Data Migration Assistant (DMA) that provides reports of your migration progress and can provide optimization suggestions. It enables you to assess the readiness of your on-premises database before migration, identify issues and opportunities for improvement, and manage your migration for you.
Azure or AWS for SQL Migration?
Choosing the right managed SQL database can be challenging; both AWS and Azure are valid options and can meet your needs. However, there are few areas in which Azure excels, namely enterprise-grade migration tooling, significant flexibility in deployment, and easy integration with existing Microsoft products.
Migration tooling
Azure automated migration capabilities you won’t find in AWS. For large migrations, automation means significant time savings. It also means greater reliability since it leaves less room for user error.
Another advantage of Azure migration tools is the inclusion of DMA. While AWS tooling can perform your migration processes with similar results to Azure tools, it cannot help you prepare for, plan, or improve your migrations. DMA, however, can provide feedback to ensure that your databases are transferred smoothly and reliably. Otherwise, with AWS, you would have to seek professional services or in-house expertise to get similar evaluation and guidance.
Deployment options
Azure supports the widest range of deployment options. AWS does not provide as many configurations for databases as Azure, or support hybrid deployments with the same ease. Additionally, migrating databases to AWS can lock you into AWS services for the remaining life of your database.
Meanwhile, migrating to Azure can provide you with the security of flexibility. When you choose Azure your data can be migrated back on-premises or back to a SQL Server instance in the cloud of your choice with minimal issues.
Licensing and Microsoft integrations
AWS RDS only supports license-included deployments. Even if you already have Microsoft licenses, you’ll be forced to repurchase licenses through service fees. With Azure, you can either include licenses in fees or to bring your existing licenses, reducing technical debt.
Another benefit of Azure is built-in integration with existing Microsoft tools, such as Active Directory or Office 365. You can use these tools with AWS, but you will not get the same support or ease of integration that you get with Azure. If your organization relies on Microsoft products, ease of integration, and assured support, then you might want to opt for Azure.
My Verdict: Select Azure for Enterprise Deployments
AWS is a great choice for smaller migrations or organizations that are already running significant workloads in the AWS cloud. However, for larger enterprise migrations, Azure is the clear winner. Microsoft provides much more powerful options for planning and automating your migration, and provides far more granular deployment options to let you customize resource utilization and scalability. Even without the large discounts provided by the Hybrid Benefits program, Azure is a great option. If you’re moving SQL Server, selecting Azure is a no-brainer.