我有一个使用mysqldump导出的2.5 GB的生产数据库。
我试图通过运行将该.dump文件导入另一台服务器


  mysql -uroot moodle

它会运行几秒钟并卡住。当我检查mysql_error.log

2018-06-27 11:14:36 5000 [ERROR] Incorrect definition of table mysql.column_stats: expected column 'max_value' at position 4 to have type varbinary(255), found type varchar(255).
2018-06-27 11:18:33 5124 [Warning] InnoDB: A long semaphore wait:
--Thread 5200 has waited at ibuf0ibuf.cc line 4403 for 241.00 seconds the semaphore:
Mutex at 00C3C3F0, Mutex IBUF created ibuf0ibuf.cc:516, lock var 2

2018-06-27 11:18:33 5124 [Warning] InnoDB: A long semaphore wait:
--Thread 4212 has waited at ibuf0ibuf.cc line 4403 for 241.00 seconds the semaphore:
Mutex at 00C3C3F0, Mutex IBUF created ibuf0ibuf.cc:516, lock var 2

2018-06-27 11:18:33 5124 [Warning] InnoDB: A long semaphore wait:
--Thread 3956 has waited at btr0pcur.cc line 444 for 241.00 seconds the semaphore:
X-lock on RW-latch at 04844024 created in file buf0buf.cc line 1478
a writer (thread id 4440) has reserved it in mode  exclusive
number of readers 0, waiters flag 1, lock_word: 0
Last time read locked in file not yet reserved line 0
Last time write locked in file btr0cur.cc line 293
2018-06-27 11:18:33 5124 [Warning] InnoDB: A long semaphore wait:
--Thread 4440 has waited at buf0buf.cc line 4145 for 241.00 seconds the semaphore:
S-lock on RW-latch at 0483BA74 created in file buf0buf.cc line 1478
a writer (thread id 0) has reserved it in mode  exclusive
number of readers 0, waiters flag 1, lock_word: 0
Last time read locked in file dict0stats.cc line 1556
Last time write locked in file buf0buf.cc line 5349
2018-06-27 11:18:33 5124 [Note] InnoDB: A semaphore wait:
--Thread 5200 has waited at ibuf0ibuf.cc line 4403 for 241.00 seconds the semaphore:
Mutex at 00C3C3F0, Mutex IBUF created ibuf0ibuf.cc:516, lock var 2


在生产数据库中工作正常,会出现什么问题?
我在Windows Server 2012中使用10.2.8-MariaDB - mariadb.org binary distribution xampp 3.2.2

最佳答案

尝试运行mysql_upgrade_service命令

mysql_upgrade_service --service=MySQL


查看更多详细信息https://mariadb.com/kb/en/library/mariadb-vs-mysql-compatibility/

关于mysql - 将生产数据库导入另一台服务器会引发错误,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/51056933/

10-15 06:34