我已经安装了MySQL一段时间了,但现在我发现我需要使用InnoDB
引擎,但是还没有这样的引擎:
mysql> show engines;
+------------+---------+-----------------------------------------------------------+--------------+------+------------+
| Engine | Support | Comment | Transactions | XA | Savepoints |
+------------+---------+-----------------------------------------------------------+--------------+------+------------+
| CSV | YES | CSV storage engine | NO | NO | NO |
| MRG_MYISAM | YES | Collection of identical MyISAM tables | NO | NO | NO |
| MEMORY | YES | Hash based, stored in memory, useful for temporary tables | NO | NO | NO |
| MyISAM | DEFAULT | Default engine as of MySQL 3.23 with great performance | NO | NO | NO |
+------------+---------+-----------------------------------------------------------+--------------+------+------------+
4 rows in set (0.00 sec)
但我发现MySQL在其插件目录中有InnoDB
个库:
root@AY130703163117124510Z plugin]# ls
ha_archive.a ha_blackhole.la ha_example.so ha_federated.so.0 ha_innodb_plugin.so libdaemon_example.a mypluglib.la
ha_archive.la ha_blackhole.so ha_example.so.0 ha_federated.so.0.0.0 ha_innodb_plugin.so.0 libdaemon_example.la mypluglib.so
ha_archive.so ha_blackhole.so.0 ha_example.so.0.0.0 ha_innodb.a ha_innodb_plugin.so.0.0.0 libdaemon_example.so mypluglib.so.0
ha_archive.so.0 ha_blackhole.so.0.0.0 ha_federated.a ha_innodb.la ha_innodb.so libdaemon_example.so.0 mypluglib.so.0.0.0
ha_archive.so.0.0.0 ha_example.a ha_federated.la ha_innodb_plugin.a ha_innodb.so.0 libdaemon_example.so.0.0.0
ha_blackhole.a ha_example.la ha_federated.so ha_innodb_plugin.la ha_innodb.so.0.0.0 mypluglib.a
[root@AY130703163117124510Z plugin]#
我不想遇到任何不确定的问题,那么如何启用InnoDB
?
答案 0 :(得分:1)
转到my.cnf文件,从那里你可以启用它。在完成重启服务器之后:
http://dev.mysql.com/doc/refman/5.1/en/innodb-parameters.html#option_mysqld_innodb
或者您可以在运行时加载InnoDB插件:
http://dev.mysql.com/doc/refman/5.1/en/replacing-builtin-innodb.html
浏览以下链接
http://dev.mysql.com/doc/refman/4.1/en/innodb-configuration.html
http://stackoverflow.com/questions/4757589/how-to-enable-innodb-in-mysql
答案 1 :(得分:0)