AWS RDS Read Replicas for Magento and WordPress

S3Sonic for Magento AWS RDS Read Replicas

S3Sonic Overview

As part of our S3 Titanium High Availablity Series for Magento Open-Source, we introduced our S3Sonic module to offer easy on-the-fly RDS Read Replica provisioning for AWS RDS instances.

Our S3Sonic High-Availability module will allow the configuration and use of AWS Database Read Replicas from the Magento 2.2.5+ admin console.

RDS read replicas allow offloading database queries from the master database RDS instance, and then distribution among the AWS MySQL/Aurora RDS read replicas. Overall this type of configuration should increase throughput, offer better performance, and add database redundancy.

Additionally, should the master database go offline for any reason, a read replica can simply be promoted to the new read/write Master in a few minutes, and all without data loss.

aMiSTACX Magento 2 AWS RDS Read Replicas S3Sonic

S3Sonic Configuration

Any S3 Titanium stack, and any designated Developer stack will allow the use of the S3Sonic module. Please reference your stack guide for more information, or contact support for assistance with Developer stacks and installation. [Newer G6F stacks have the option to install S3Sonic during CFT deployment.]

For Magento Open Source, prior to operation, make sure you have the latest S3Sonic version installed.

From CLI:

cd /var/www/magento

sudo composer update amistacx/s3sonic

sudo ./amistacx.sh #make the file “X” executable if required.

sudo php bin/magento module:enable Amistacx_S3Sonic

From Magento Admin Dashboard:

Step 1. Get AWS IAM Keys. You will attach permission policy: AmazonRDSFullAccess

Step 2. Enter the keys in S3Sonic, and clear Magento’s cache as directed.

Step 3. Enter the name of your replica in the field called Instance Identifier, and then click “SAVE” at the top-right. Clear cache as directed.

Step 4. You can monitor the spawn of the RR in A51 or the AWS console.

Note: To terminate a replica, you must do it from AWS RDS.

S3Sonic and SSL/TLS for RDS

S3Sonic has the ability to easily add encryption from the Magento EC2 to the AWS RDS instance. This extra piece of security helps thwart sniffing between the multiple endpoints. A must if you need to have your RDS set to “Public”.

S3Sonic SSL/TLS Configuration for Magento 2 and AWS RDS

Step 1. Set SSL to “YES”

Step 2. Upload your AWS RDS PEM file.

A51 Monitoring and Control Integration

Introduced in late 2022, our A51 console now has RDS read replica awareness. A51 will report the status of a Parent [Master] and all of the replicas.

A51 dashboard showing AWS Read Replicas and parent database.

Deployment Video for Magento Open Source

Deployment Video for WordPress

S3Sonic Versions

## [2.1.4] – 2022-11-20
### Added
+PHP 8.1 supporting.
+Bug fixes
+Magento 2.4.5 supporting

Sometimes two is better than one.

Lead~Robot

Weaponize your Business with aMiSTACX!