Bug #57008 error messages for outdated system tables should mention mysql_upgrade
Submitted: 24 Sep 2010 15:30 Modified: 14 Jun 2013 19:41
Reporter: Axel Schwenke Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server Severity:S4 (Feature request)
Version:5.5.6 OS:Any
Assigned to: Matthew Lord CPU Architecture:Any

[24 Sep 2010 15:30] Axel Schwenke
Description:
Several subsystems (permission system, event scheduler, performance schema) check if the respective system tables are usable and complain when not. Current example are the missing performance schema tables after a binary upgrade from 5.1 to 5.5:

[ERROR] Native table 'performance_schema'.'EVENTS_WAITS_CURRENT' has the wrong structure
[ERROR] Native table 'performance_schema'.'EVENTS_WAITS_HISTORY' has the wrong structure
...

While those messages are correct, they don't provide any information what the underlying problem might be and what to do.

How to repeat:
Do a binary upgrade from 5.1 to 5.5.

Suggested fix:
Extend those messages to mention the possible cause: a binary upgrade was done but mysql_upgrade was not run. I.e.

[ERROR] Native table 'performance_schema'.'EVENTS_WAITS_CURRENT' has the wrong structure; it seems your system tables don't match your server version, you should run mysql_upgrade to correct this.

Note: there is slightly related bug #54467
[14 Jun 2013 19:41] Matthew Lord
Thank you for the great feature request, Axel!

I'm closing this now, as the feature has been implemented in recent versions of MySQL.

Thanks again!