首页 > 解决方案 > MySQL崩溃,innodb试图访问表空间边界之外的页码

问题描述

我在 Windows 2012 服务器上运行 MySQL (5.7)。其中一张表(> 100 万条记录)似乎已损坏。mysql错误日志显示

2019-01-16T09:41:09.256990Z 0 [Note] InnoDB: Buffer pool(s) load completed at 190116 14:41:09
2019-01-16T09:41:25.153201Z 2 [Warning] IP address 'ip' could not be resolved: No such host is known. 
2019-01-16T09:41:25.620502Z 3 [ERROR] InnoDB: Trying to access page number 3 in space 470, space name shop/products, which is outside the tablespace bounds. Byte offset 0, len 16384, i/o type read. If you get this error at mysqld startup, please check that your my.cnf matches the ibdata files that you have in the MySQL server.
2019-01-16T09:41:25.623268Z 3 [ERROR] InnoDB: Server exits.

当我在此表中插入记录时出现此问题。该表有 22 个索引列,其中之一是 FULLTEXT。

我也尝试过 innodb_force_recovery = [1 - 6],但我无法转储产品表。每当我尝试访问此表时,它都会使数据库服务器崩溃。

有什么方法可以转储或恢复此表。我有旧的备份,所以我不能使用那个。谢谢 :)

MYSQL 服务器详细信息:

更新

我正面临一个奇怪的问题。当我执行 table status 命令时,它显示行数为零,

但是 mysql 数据文件夹中的 products.ibd 文件大小为 4GB。

SHOW TABLE STATUS FROM shop LIKE 'products';

在此处输入图像描述

操作系统的文件大小

在此处输入图像描述

标签: mysqldatabaserecovery

解决方案


推荐阅读