Migrate Azure Cosmos DB for PostgreSQL Server to Another Region with Read Replicasβ
Workflow Summaryβ
- Create a read replica in the target region via the Azure portal.
- Configure firewall rules and virtual network settings for the read replica.
- Monitor replication status to ensure data synchronization.
- Promote the read replica to become the new primary cluster in the target region.
- Decommission the original primary cluster in the source region.
1. Create a Read Replica in the Target Regionβ
- In the Azure portal, navigate to the primary cluster.
- Under Cluster management, select Replicate data globally.
- Click Add replica, provide a name for the read replica, and select the target region.
- Click OK to initiate creation.
- Manually configure firewall rules and virtual network settings on the read replica to allow application access.
- Confirm that the replica inherits admin and user accounts from the primary cluster.
3. Monitor Replication Statusβ
- Use the Azure portal to monitor Read Replica Lag and confirm that data is synchronizing properly.
- Ensure CPU and RAM utilization on the read replica remain within acceptable limits.
- Once replication is complete and verified, promote the read replica to the primary cluster.
- In the Azure portal, select the read replica, click Promote, and confirm the operation.
- After promotion, the read replica becomes the new primary cluster in the target region.
5. Decommission the Original Primary Clusterβ
- After ensuring the new primary cluster is fully operational, decommission the source primary cluster.
- In the Azure portal, navigate to the original primary cluster and select Delete.
- Confirm deletion to stop billing for the source cluster.
Considerationsβ
- Expect brief downtime during the promotion process; plan accordingly.
- Monitor replication lag to ensure no data is lost before promotion.
- Verify that applications, firewall rules, and virtual networks are correctly configured for the new primary cluster.