Best practices with Amazon Aurora PostgreSQL
Following, you can find several best practices for managing your Amazon Aurora PostgreSQL DB cluster. Be sure to also review basic maintenance tasks. For more information, see Performance and scaling for Amazon Aurora PostgreSQL.
Topics
Avoiding slow performance, automatic restart, and failover for Aurora PostgreSQL DB instances
Fast recovery after failover with cluster cache management for Aurora PostgreSQL
Using Amazon CloudWatch metrics to analyze resource usage for Aurora PostgreSQL
Using logical replication to perform a major version upgrade for Aurora PostgreSQL
Avoiding slow performance, automatic restart, and failover for Aurora PostgreSQL DB instances
If you're running a heavy workload or workloads that spike beyond the allocated resources of your DB instance, you can exhaust the resources on which you're running your application and Aurora database. To get metrics on your database instance such as CPU utilization, memory usage, and number of database connections used, you can refer to the metrics provided by Amazon CloudWatch, Performance Insights, and Enhanced Monitoring. For more information on monitoring your DB instance, see Monitoring metrics in an Amazon Aurora cluster.
If your workload exhausts the resources you're using, your DB instance might slow down, restart, or even fail over to another DB instance. To avoid this, monitor your resource utilization, examine the workload running on your DB instance, and make optimizations where necessary. If optimizations don't improve the instance metrics and mitigate the resource exhaustion, consider scaling up your DB instance before you reach its limits. For more information on available DB instance classes and their specifications, see Amazon Aurora DB instance classes.