Migrating Your Databases to Amazon Aurora - Migrating Your Databases to Amazon Aurora

Migrating Your Databases to Amazon Aurora

Publication date: July 28, 2021 (Document history)

Abstract

Amazon Aurora is a MySQL and PostgreSQL-compatible, enterprise grade relational database engine. Amazon Aurora is a cloud-native database that overcomes many of the limitations of traditional relational database engines. The goal of this whitepaper is to highlight best practices of migrating your existing databases to Amazon Aurora. It presents migration considerations and the step-by-step process of migrating open- source and commercial databases to Amazon Aurora with minimum disruption to the applications.

Are you Well-Architected?

The AWS Well-Architected Framework helps you understand the pros and cons of the decisions you make when building systems in the cloud. The six pillars of the Framework allow you to learn architectural best practices for designing and operating reliable, secure, efficient, cost-effective, and sustainable systems. Using the AWS Well-Architected Tool, available at no charge in the AWS Management Console, you can review your workloads against these best practices by answering a set of questions for each pillar.

For more expert guidance and best practices for your cloud architecture—reference architecture deployments, diagrams, and whitepapers—refer to the AWS Architecture Center.

Introduction

For decades, traditional relational databases have been the primary choice for data storage and persistence. These database systems continue to rely on monolithic architectures and were not designed to take advantage of cloud infrastructure. These monolithic architectures present many challenges, particularly in areas such as cost, flexibility, and availability. In order to address these challenges, AWS redesigned relational database for the cloud infrastructure and introduced Amazon Aurora.

Amazon Aurora is a MySQL and PostgreSQL-compatible relational database engine that combines the speed, availability, and security of high-end commercial databases with the simplicity and cost-effectiveness of open-source databases. Aurora provides up to five times better performance than MySQL, three times better performance than PostgreSQL and comparable performance of high-end commercial databases. Amazon Aurora is priced at 1/10th the cost of commercial engines.

Amazon Aurora is available through the Amazon Relational Database Service (Amazon RDS) platform. Like other Amazon RDS databases, Aurora is a fully managed database service. With the Amazon RDS platform, most database management tasks such as hardware provisioning, software patching, setup, configuration, monitoring, and backup are completely automated.

Amazon Aurora is built for mission-critical workloads and is highly available by default. An Aurora database cluster spans multiple Availability Zones in a Region, providing out-of-the-box durability and fault tolerance to your data across physical data centers. An Availability Zone is composed of one or more highly available data centers operated by Amazon. Availability Zones are isolated from each other and are connected through low-latency links. Each segment of your database volume is replicated six times across these Availability Zones.

Amazon Aurora enables dynamic resizing for database storage space. Aurora cluster volumes automatically grow as the amount of data in your database increases with no performance or availability impact—so there is no need for estimating and provisioning large amount of database storage ahead of time. The storage space allocated to your Amazon Aurora database cluster will automatically increase up to a maximum size of 128 tebibytes (TiB) and will automatically decrease when data is deleted.

Aurora's automated backup capability supports point-in-time recovery of your data, enabling you to restore your database to any second during your retention period, up to the last five minutes. Automated backups are stored in Amazon Simple Storage Service (Amazon S3), which is designed for 99.999999999% durability. Amazon Aurora backups are automatic, incremental, and continuous and have no impact on database performance.

For applications that need read-only replicas, you can create up to 15 Aurora Replicas per Aurora database with very low replica lag. These replicas share the same underlying storage as the source instance, lowering costs and avoiding the need to perform writes at the replica nodes. Optionally, Aurora Global Database can be used for high read throughputs across six Regions up to 90 read replicas.

Amazon Aurora is highly secure and allows you to encrypt your databases using keys that you create and control through AWS Key Management Service (AWS KMS). On a database instance running with Amazon Aurora encryption, data stored at rest in the underlying storage is encrypted, as are the automated backups, snapshots, and replicas in the same cluster. Amazon Aurora uses SSL (AES-256) to secure data in transit.

For a complete list of Aurora features, refer to the Amazon Aurora product page. Given the rich feature set and cost effectiveness of Amazon Aurora, it is increasingly viewed as the go-to database for mission-critical applications.

Amazon Aurora Serverless v2 is the new version of Aurora Serverless, an on- demand, automatic scaling configuration of Amazon Aurora that automatically starts up, shuts down, and scales capacity up or down based on your application's needs. It scales instantly from hundreds to hundreds-of-thousands of transactions in a fraction of a second. As it scales, it adjusts capacity in fine-grained increments to provide just the right amount of database resources that the application needs. There is no database capacity for you to manage, you pay only for the capacity your application consumes, and you can save up to 90% of your database cost compared to the cost of provisioning capacity for peak.

Aurora Serverless v2 is a simple and cost-effective option for any customer who cannot easily allocate capacity because they have variable and infrequent workloads or have a large number of databases. If you can predict your application’s requirements and prefer the cost certainty of fixed-size instances, then you may want to continue using fixed-size instances.

Amazon Aurora capabilities discussed in this whitepaper apply to both MySQL and PostgreSQL database engines, unless otherwise specified. However, the migration practices discussed in this paper are specific to Aurora MySQL database engine. For more information about Aurora best practices specific to PostgreSQL database engine, refer to Working with Amazon Aurora PostgreSQL in the Amazon Aurora user guide.