[MDEV-19137] mysql_upgrade from mysql 5.7 to MariaDB 10.3.12 fails for "sys" schema Created: 2019-04-02  Updated: 2019-08-19  Resolved: 2019-04-03

Status: Closed
Project: MariaDB Server
Component/s: Server
Affects Version/s: 10.3.12
Fix Version/s: N/A

Type: Bug Priority: Minor
Reporter: Faisal Saeed (Inactive) Assignee: Michael Widenius
Resolution: Fixed Votes: 0
Labels: None
Environment:

CentOS 7.4



 Description   

Upgrading from MySQL 5.7 to MariaDB 10.3.12 gives a lot of sys schema related errors as attached.

Process:
1. Remove MySQL 5.7 binaries (rpm -qa | grep mysql | xargs rpm -e)
2. Install MariaDB (yum -y install MariaDB-server)
3. Execute: mysql_upgrade

After the upgrade completes with the error messages, a server restart does not show any error messages, but a re-execution of mysql_upgrade still throws the same error messages.

Just to test, I dropped the sys schema and did a server restart followed by mysql_upgrade and did not get any issues.



 Comments   
Comment by Elena Stepanova [ 2019-04-02 ]

I don't see many options here.
We don't support sys schema. The server still upgrades, restarts after upgrade without errors and seemingly works.
What should we do, hardcode hiding errors about sys schema?
Leaving it to serg to decide if anything should/can be done.

Comment by Faisal Saeed (Inactive) [ 2019-04-02 ]

I removed the sys schema after the upgrade and everything still worked fine for the simple test I did.

Comment by Michael Widenius [ 2019-04-02 ]

We should have mysql_upgrade remove the sys schema as part of the upgrade.
No reason to have the user confused by not relevant error messages.

Comment by Sergei Golubchik [ 2019-04-03 ]

I disagree.

mysql_upgrade cannot remove every single view or a stored procedure that refers to an non-existing table, thiis is not part of the upgrade.

Comment by Fernando Mattera [ 2019-07-17 ]

So, it's safe/supported remove sys schema after/before run mysql_upgrade?

I appreciate a satisfactory answer because I have to migrate one production db.

Thanks in Advance,

Fernando.

Comment by Sergei Golubchik [ 2019-08-19 ]

Yes

Generated at Thu Feb 08 08:49:20 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.