MySQL打開時InnoDB引擎被禁用了怎么辦
發(fā)表時間:2023-07-24 來源:明輝站整理相關軟件相關文章人氣:
[摘要]MySQL啟動時InnoDB引擎被禁用了怎么辦?最近在工作中遇到一個問題,現(xiàn)將解決的方法分享出來供大家參考學習,下面這篇文章主要給大家介紹了關于MySQL啟動時InnoDB引擎被禁用了的解決方法,需...
MySQL啟動時InnoDB引擎被禁用了怎么辦?最近在工作中遇到一個問題,現(xiàn)將解決的方法分享出來供大家參考學習,下面這篇文章主要給大家介紹了關于MySQL啟動時InnoDB引擎被禁用了的解決方法,需要的朋友們下面跟著小編來一起學習學習吧。希望能幫助到大家。
發(fā)現(xiàn)問題
今天在工作中,從本地數(shù)據(jù)庫復制表數(shù)據(jù)到虛擬機 CentOS 6.6 上的數(shù)據(jù)庫時,得到提示:
Unknown table engine 'InnoDB'
于是在服務器 MySQL 中查看了引擎:
mysql> show engines\G
得到:
*************************** 1. row ***************************
Engine: MyISAM
Support: DEFAULT
Comment: MyISAM storage engine
Transactions: NO
XA: NO
Savepoints: NO
*************************** 2. row ***************************
Engine: CSV
Support: YES
Comment: CSV storage engine
Transactions: NO
XA: NO
Savepoints: NO
*************************** 3. row ***************************
Engine: MEMORY
Support: YES
Comment: Hash based, stored in memory, useful for temporary tables
Transactions: NO
XA: NO
Savepoints: NO
*************************** 4. row ***************************
Engine: BLACKHOLE
Support: YES
Comment: /dev/null storage engine (anything you write to it disappears)
Transactions: NO
XA: NO
Savepoints: NO
*************************** 5. row ***************************
Engine: MRG_MYISAM
Support: YES
Comment: Collection of identical MyISAM tables
Transactions: NO
XA: NO
Savepoints: NO
*************************** 6. row ***************************
Engine: PERFORMANCE_SCHEMA
Support: YES
Comment: Performance Schema
Transactions: NO
XA: NO
Savepoints: NO
*************************** 7. row ***************************
Engine: ARCHIVE
Support: YES
Comment: Archive storage engine
Transactions: NO
XA: NO
Savepoints: NO
*************************** 8. row ***************************
Engine: FEDERATED
Support: NO
Comment: Federated MySQL storage engine
Transactions: NULL
XA: NULL
Savepoints: NULL
*************************** 9. row ***************************
Engine: InnoDB
Support: NO
Comment: Supports transactions, row-level locking, and foreign keys
Transactions: NULL
XA: NULL
Savepoints: NULL
rows in set (0.00 sec)
在 InnoDB 的 Supports 為 NO
解決方法
編輯 my.cnf
[root@localhost mysql]# vim /etc/my.cnf
把其中 innodb = OFF 改為 innodb = ON
同時把 skip-innodb 注釋掉即可。
相關推薦:
MySQL存儲引擎MyISAM和InnoDB之間的比較
mysql中innoDB鎖的介紹
MySQL InnoDB和MyISAM數(shù)據(jù)引擎的差別分析詳解
以上就是MySQL啟動時InnoDB引擎被禁用了怎么辦的詳細內容,更多請關注php中文網其它相關文章!
學習教程快速掌握從入門到精通的SQL知識。