RDS PostgreSQL 11.1: high CPU and Write IOPS after upgrade?

0

After upgrading our PostgreSQL database instance ("livedb") from 9.5 to 11.1, we are seeing CPU and Write IOPS spikes after 5 minute intervals, and ~20% usage when idle which is much more than earlier.
The load has been very low since and no other changes were made in the database, but the average CPU usage is at an all-time high and we are running out of CPU credits. I tried different configurations, but currently am using the default "default.postgres11" parameter group.

mrklk
已提問 5 年前檢視次數 1638 次
3 個答案
0

After upgrading my Postgres instance from 10.6 to 11.2, I'm seeing high IOPS and my queries are taking more time to complete.

Before the upgrade, my long running queries takes 300-400 write IOPS to complete.
After the upgrade, my long running queries takes 1000-1200 write IOPS to complete.

已回答 5 年前
0

Same problem here also if with Sql Server.

after an update to sql server some days ago, I am having problem of HIGH CPU utilization.

It is exactly the same situation of november (when I updated sql instance to a major release). I just rebooted the instance but did NOT solved the problem.... Please help me.

已回答 5 年前
0

Please note by default RDS postgres makes use of Pg_upgrade call for the major version upgrade. Although RDS is managed service but it doesn't applies any additional methods/activities over the Vanila Postgres defined actions/workflows. With reference to the following official PostgreSQL documentation[1] :

"Statistics: Because optimizer statistics are not transferred by pg_upgrade, you will be instructed to run a command to regenerate that information at the end of the upgrade."

Additionally, please check the note under AWS RDS PostgreSQL Major version Upgrade document[2], which states “After you have completed the upgrade, you should run the ANALYZE operation to refresh the pg_statistic table“. In future, you can make use of the below method for running ANALYZE for in a better and a faster way.

This also makes SQLs performing better. A better way to do that is using vacuumdb[3], like this:

vacuumdb -U [your user] -d [your database] -Ze -h [your rds endpoint]

It will optimize your database execution plan only, not freeing space, but will take less time than a complete vacuum.

References/Links:

[1] https://www.postgresql.org/docs/10/static/pgupgrade.html
[2] https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/USER_UpgradeDBInstance.PostgreSQL.html
[3] https://www.postgresql.org/docs/10/static/app-vacuumdb.html

已回答 5 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南