当我启动 mariadb 10.4.8 服务器时,我的 error.log 文件中有许多这样的错误消息引用了无法打开的不同文件:
2019-09-30 17:38:19 0 [ERROR] InnoDB: Cannot open datafile for read-only: '/tmp/#sql50b_8808_1.ibd' OS error: 71
2019-09-30 17:38:19 0 [ERROR] InnoDB: Cannot read first page of './tmp/#sql50b_8808_1.ibd' I/O error
2019-09-30 17:38:19 0 [Note] InnoDB: Cannot read first page in datafile: ./tmp/#sql50b_8808_1.ibd, Space ID:18446744073709551615, Flags: 0
2019-09-30 17:38:19 0 [ERROR] InnoDB: Operating system error number 2 in a file operation.
2019-09-30 17:38:19 0 [ERROR] InnoDB: The error means the system cannot find the path specified.
2019-09-30 17:38:19 0 [ERROR] InnoDB: If you are installing InnoDB, remember that you must create directories yourself, InnoDB does not create them.
2019-09-30 17:38:19 0 [ERROR] InnoDB: Could not find a valid tablespace file for ``tmp`.`#sql50b_8808_1``. Please refer to https://mariadb.com/kb/en/innodb-data-dictionary-troubleshooting/ for how to resolve the issue.
2019-09-30 17:38:19 0 [Warning] InnoDB: Ignoring tablespace for `tmp`.`#sql50b_8808_1` because it could not be opened.
我没有名为 的数据库tmp
,因此数据字典故障排除说明没有帮助。
我在我的文件系统中找不到任何以#sql
任何地方开头的文件,但是
SELECT * FROM INFORMATION_SCHEMA.INNODB_SYS_TABLES
WHERE NAME LIKE '%#sql%';
返回 65 行,包括与上述文件关联的行。有什么方法可以清理它,这样 MariaDB 就不会尝试打开这些不存在的文件吗?