0

从我们的旧 MySQL 服务器迁移到我们的新服务器出错了。

引用 MySQL 升级指南:

一旦发布系列达到通用 (GA) 状态,就支持在发布系列内升级(从一个 GA 版本到另一个 GA 版本)。例如,支持从 MySQL 8.0.x 升级到 8.0.y。(不支持涉及开发状态非 GA 版本的升级。)还支持跳过版本。例如,支持从 MySQL 8.0.x 升级到 8.0.z。MySQL 8.0.11 是 MySQL 8.0 版本系列中的第一个 GA 状态版本。

旧服务器(版本 8.0.11):

mysqldump -u root -p --all-databases --verbose -r 2020_09_16_alldb.sql

新服务器(版本 8.0.21,全新安装):

mysql -u root -p < 2020_09_16_alldb.sql

首次登录成功。然后我试图重新启动服务,但它不会再出现了。

2020-09-16T20:09:36.718949Z 0 [System] [MY-010116] [Server] /usr/sbin/mysqld (mysqld 8.0.21) starting as process 1819
2020-09-16T20:09:36.725816Z 1 [System] [MY-013576] [InnoDB] InnoDB initialization has started.
2020-09-16T20:09:38.178086Z 1 [System] [MY-013577] [InnoDB] InnoDB initialization has ended.
2020-09-16T20:09:38.306305Z 0 [System] [MY-011323] [Server] X Plugin ready for connections. Bind-address: '::' port: 33060, socket: /var/run/mysqld/mysqlx.sock
2020-09-16T20:09:38.408186Z 0 [Warning] [MY-010068] [Server] CA certificate ca.pem is self signed.
2020-09-16T20:09:38.408316Z 0 [System] [MY-013602] [Server] Channel mysql_main configured to support TLS. Encrypted connections are now supported for this channel.
2020-09-16T20:09:38.415771Z 0 [Warning] [MY-013143] [Server] Column count of mysql.user is wrong. Expected 51, found 49. The table is probably corrupted
2020-09-16T20:09:38.415930Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.db. The table is probably corrupted!
2020-09-16T20:09:38.416058Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.tables_priv. The table is probably corrupted!
2020-09-16T20:09:38.416176Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.tables_priv. The table is probably corrupted!
2020-09-16T20:09:38.416298Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.columns_priv. The table is probably corrupted!
2020-09-16T20:09:38.416422Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.procs_priv. The table is probably corrupted!
2020-09-16T20:09:38.416544Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.procs_priv. The table is probably corrupted!
2020-09-16T20:09:38.416670Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.proxies_priv. The table is probably corrupted!
2020-09-16T20:09:38.416797Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.proxies_priv. The table is probably corrupted!
2020-09-16T20:09:38.416921Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.proxies_priv. The table is probably corrupted!
2020-09-16T20:09:38.417082Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.role_edges. The table is probably corrupted!
2020-09-16T20:09:38.417212Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.role_edges. The table is probably corrupted!
2020-09-16T20:09:38.417344Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.default_roles. The table is probably corrupted!
2020-09-16T20:09:38.417475Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.default_roles. The table is probably corrupted!
2020-09-16T20:09:38.417617Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.global_grants. The table is probably corrupted!
2020-09-16T20:09:38.417756Z 0 [Warning] [MY-013139] [Server] Cannot load from mysql.password_history. The table is probably corrupted!
2020-09-16T20:09:38.418298Z 0 [ERROR] [MY-013139] [Server] Cannot load from mysql.global_grants. The table is probably corrupted!
2020-09-16T20:09:38.418502Z 0 [ERROR] [MY-010952] [Server] The privilege system failed to initialize correctly. For complete instructions on how to upgrade MySQL to a new version please see the 'Upgrading MySQL' section from the MySQL manual.
2020-09-16T20:09:38.418833Z 0 [ERROR] [MY-010119] [Server] Aborting
2020-09-16T20:09:39.884396Z 0 [System] [MY-010910] [Server] /usr/sbin/mysqld: Shutdown complete (mysqld 8.0.21)  MySQL Community Server - GPL

按照其他人的建议尝试了这个:

mysql_upgrade -u root -p  

                                                                                                               

结果:

mysql_upgrade 客户端现已弃用。升级客户端执行的操作现在由服务器完成。

请指教。

4

0 回答 0