Search code examples
mysqlamazon-web-servicesamazon-aurora

Unable to enable performance_schema for AWS Aurora MySQL


How can I enable performance_schema for AWS Aurora MySQL?

I have enabled Performance Insights. The table "events_statements_summary_by_digest" is empty.

I set "performance_schema=1" in DB parameters group, Cluster parameters group, and restarted server.

But "show global variables" still outputs "performance_schema=0" and the table "events_statements_summary_by_digest" is empty.


Solution

  • When you enable performance insights, the performance schema isn't turned on until you reboot the instance. In your case, you rebooted after setting performance_schema=1. This is an incompatible configuration because in order for insights to automatically manage the schema, the value of performance_schema must be zero. (source: https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_PerfInsights.EnableMySQL.html#USER_PerfInsights.EnableMySQL.options)

    You should determine whether the performance schema is currently being automatically or manually managed, and set the correct configurations depending on what you want. To go from automatic to manual, there are 5 parameters you need to set. For manual to automatic, you can do it through the RDS console. https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/USER_PerfInsights.EnableMySQL.html#USER_PerfInsights.EnableMySQL.RDS