SHOW ENGINES;不列出 InnoDB

SHOW ENGINES;不列出 InnoDB

从昨天开始,我在 Ubuntu 上安装的 Mysql 中的 InnoDB 表不再起作用,我尝试使用 Navicat 打开它们,但出现“未知表引擎‘InnoDB’”错误。

当我尝试列出所有使用Show Engines;它的引擎时返回;

+------------+---------+----------------------------------------------------------------+--------------+------+------------+
| Engine     | Support | Comment                                                        | Transactions | XA   | Savepoints |
+------------+---------+----------------------------------------------------------------+--------------+------+------------+
| MyISAM     | DEFAULT | Default engine as of MySQL 3.23 with great performance         | NO           | NO   | NO         | 
| MRG_MYISAM | YES     | Collection of identical MyISAM tables                          | NO           | NO   | NO         | 
| BLACKHOLE  | YES     | /dev/null storage engine (anything you write to it disappears) | NO           | NO   | NO         | 
| CSV        | YES     | CSV storage engine                                             | NO           | NO   | NO         | 
| MEMORY     | YES     | Hash based, stored in memory, useful for temporary tables      | NO           | NO   | NO         | 
| FEDERATED  | NO      | Federated MySQL storage engine                                 | NULL         | NULL | NULL       | 
| ARCHIVE    | YES     | Archive storage engine                                         | NO           | NO   | NO         | 
+------------+---------+----------------------------------------------------------------+--------------+------+------------+
7 rows in set (0.00 sec)

如您所见,InnoDB 未列出,有什么建议可以解决此问题吗?或者甚至可以更改表的引擎,而不需要旧引擎?

检查日志后,我发现了这一点;

/usr/sbin/mysqld: Can't create/write to file '/tmp/ibnGBtbE' (Errcode: 13)
101129 21:03:17  InnoDB: Error: unable to create temporary file; errno: 13
101129 21:03:17 [ERROR] Plugin 'InnoDB' init function returned error.
101129 21:03:17 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.

知道如何解决这个问题吗?

答案1

那么听起来 /tmp 上的权限就乱了。

chmod 1777 /tmp

然后尝试重启mysql

答案2

检查您的 mysql 错误日志..您可能对 my.cnf 文件进行了更改,并且由于 ibdata 文件大小不正确导致 innodb 无法初始化。

相关内容