AWS Certified SysOps Administrator - Associate

Domain 2 Reliability and BCP

AWS Aurora Replication Options Introduction

Welcome back, students!

In this article, we explore the various replication options available for AWS Aurora, Amazon's cloud-native version of MySQL and PostgreSQL. Aurora is designed for high performance and scalability and offers many advantages over standard RDS implementations.

Aurora delivers significantly higher throughput compared to plain RDS MySQL and PostgreSQL, and it even provides serverless options with Aurora Capacity Units that operate similarly to DynamoDB. While this discussion focuses on replication, remember that Aurora supports both MySQL and PostgreSQL with additional AWS-specific features.

AWS has tightly controlled Aurora’s development, resulting in advanced replication capabilities that extend beyond standard RDS functionality. Although both RDS and Aurora provide read replicas and cross-region replication, Aurora also offers a Global Database feature that improves automatic failover and global data distribution.


The image illustrates the architecture of Amazon Aurora replicas within the same region, showing a writer instance and multiple reader instances across different availability zones, all connected to a shared storage volume. It highlights synchronous writes and asynchronous replication processes.

The diagram above shows the internal architecture of Aurora read-only replicas. In Aurora, replicas are read-only copies of the primary instance. The writer instance (displayed at the upper left-hand side) is connected to a shared storage volume, which is central to Aurora’s design. Additionally, the diagram highlights two asynchronous reader instances located in different availability zones. By default, Aurora supports up to 15 replicas within the same region, benefiting from synchronous replication that ensures low latency and high performance.


For cross-region replication, you can replicate data from one Aurora cluster to another in different regions. Since replicating storage data between regions introduces higher latency, the replication process is completely asynchronous. This configuration excels in disaster recovery and global read scaling scenarios. In such setups, one cluster acts as the primary while another in a different region can be promoted if a failure occurs.

The image illustrates the process of Amazon Aurora Cross-Region Replication, showing data flow from users to an Aurora cluster, through binary logs, and into another region's Aurora cluster.

The diagram above explains the binary log replication method used between a primary and secondary cluster in cross-region replication. Although synchronous replication isn't supported here due to latency, this approach provides excellent disaster recovery and read scaling benefits.


Next, let’s distinguish cross-region replication from the Aurora Global Database feature. With a Global Database, data replication across multiple regions is bidirectional. In this configuration:

  • The primary region handles all write operations.
  • Secondary clusters in other regions manage read traffic.
  • Global data replication occurs seamlessly between clusters.
  • In case of primary cluster failure, one of the secondary clusters is automatically promoted, with failover occurring in as little as one minute.

The image is a diagram of an AWS Aurora Global Database setup, showing a primary region with a primary cluster and a secondary region with a secondary cluster, connected via global database replication. It includes user connections, VPCs, and endpoints managed through Amazon Route 53.


A quick comparison of the three replication approaches is provided below:

Replication ApproachKey Features
Aurora Read-Only ReplicasUp to 15 low-latency replicas in the same region with synchronous replication via shared storage volume
Cross-Region ReplicasRead replicas available in up to five other regions with asynchronous replication; manual failover
Aurora Global DatabaseConsists of one primary cluster and up to five secondary clusters; automatic failover for global apps

The image is a comparison chart of Aurora replication types, detailing features of Aurora Replicas, Cross-Region Replicas, and Aurora Global Database.

A key difference is that cross-region replication requires manual failover, while the Aurora Global Database automatically promotes a secondary region should the primary cluster fail.


Best Practices

  • Use Aurora replicas to efficiently scale read operations.
  • Leverage cross-region replication for robust disaster recovery.
  • Utilize the Aurora Global Database for applications requiring automatic global failover.
  • Continuously monitor replication lag to manage any potential data loss (typically up to 30 seconds to one minute).

The image outlines four best practices for database management: using Aurora replicas for read scaling, leveraging cross-region replication for disaster recovery, implementing Aurora global databases for global applications, and monitoring replication lag.

It is crucial to discuss these replication strategies with business stakeholders to ensure they understand the implications of replication lag and the acceptable risk of minor data loss.

This concludes our discussion on AWS Aurora replication options. Thank you for reading, and stay tuned for more insights in our upcoming articles.

Watch Video

Watch video content

Previous
AWS RDS Replication Types Introduction