How To Fail Back To The First Region In Amazon Aurora Global Database
I am following the official documentation here https://aws.amazon.com/getting-started/hands-on/aurora-global-database/
Note: After failover, the newly promoted cluster in Europe (Paris) Region becomes a Regional aurora cluster. Once promoted you cannot add the new DB cluster back to the old Aurora Global Database as a secondary region. If you want to fail back to original region US-East (N. Virginia) or add a secondary cluster in different AWS Region, you need to repeat the steps 6 to 8 by creating a new Aurora Global Database with the newly promoted cluster as the primary cluster. See Failover for Aurora Global Database.
I am wondering about the following:
On what basis does the failover happen to secondary region? Does it happen only when the primary region is down? If I have a custom failover strategy then, can that be tied to amazon aurora global database failover as well?
When the failover happens, does it promote the secondary region's aurora to master automatically?
After failover, if I need to fail back to the primary region then, can I flip the the direction of replication back to primary from secondary somehow? Is there an automated way to do that?
Unfortunately at the moment the Aurora service does not perform the failover itself (although you could automate this through CloudWatch and Lambda triggers).
Q: Will Aurora automatically fail over to a secondary region of an Aurora Global Database?
No. If your primary region becomes unavailable, you can manually remove a secondary region from an Aurora Global Database and promote it to take full reads and writes. You will also need to point your application to the newly promoted region.
When the failover occurs the promoted instance becomes separated from the cluster, and it will become its own cluster with its own reads and writes. At this point there is no relationship between the clusters anymore your application would need to be retargeted to use this endpoint instead.
To flip back you would need to recreate an Aurora cluster in the previous region (or copy the DB changes back to the previous cluster). The simpler route might be to create a global database back to the original region then failover and retarget your application at this one.
Amazon has recently enabled write forwarding for global databases so in theory you could retarget the application back to the original region before you failover.
- → AWS SDK with Lumen
- → Using AWS Certificate with a parked domain for a shopify store
- → laravel or AWS don't detect my https
- → S3 putObject callback not returning expected objects
- → Amazon S3 image hosting with Shopify
- → Redirection to https not working using AWS Elastic Beanstalk
- → Shopify app showing request blocked by an extension
- → AWS Iam commands, Working correct in terminal and not working in Laravel/PHP AWS SDK
- → Violates the following Content Security Policy directive: *** in Shopify
- → AWS S3 cannot delete objects in bucket via PHP SDK
- → Laravel s3 multiple buckets
- → AWS IoT private.pem.key doesn't exist
- → Supervise queue in laravel 5.1