在my.ini(linux下/etc/my.cnf)加上skip-innodb,就可以了。
我這樣設置后,在linux下都沒問題,今天在我本機winXP啟動MYSQL,提示啟動不起來。看下mysql目錄的錯誤日志:
引用
090613 10:15:27 [ERROR] Default storage engine (InnoDB) is not available
090613 10:15:27 [ERROR] Aborting
090613 10:15:27 [Note] C:\www\mysql\bin\mysqld-nt: Shutdown complete
估計是上次加了參數后,一直沒啟動起來。。。已經很久沒用本機的mysql了。
查了下,原來my.ini里有一句:default-storage-engine=INNODB,把默認的engine設為INNODB,而我又加了skip-innodb,怪不得啟不來了。
將default-storage-engine改為MYISAM,MYSQL啟動OK!
在skip-innodb下,data目錄下的ibdata1,ib_logfile0,ib_logfile1這三個文件就不需要了,就可以刪除。
測試了下,在沒加skip-innodb時,刪除了這三個文件,啟動時會自動創建這三個文件,日志如下:
引用
InnoDB: The first specified data file .\ibdata1 did not exist:
InnoDB: a new database to be created!
090613 10:19:37 InnoDB: Setting file .\ibdata1 size to 10 MB
InnoDB: Database physically writes the file full: wait...
090613 10:19:37 InnoDB: Log file .\ib_logfile0 did not exist: new to be created
InnoDB: Setting log file .\ib_logfile0 size to 24 MB
InnoDB: Database physically writes the file full: wait...
090613 10:19:38 InnoDB: Log file .\ib_logfile1 did not exist: new to be created
InnoDB: Setting log file .\ib_logfile1 size to 24 MB
InnoDB: Database physically writes the file full: wait...
InnoDB: Doublewrite buffer not found: creating new
InnoDB: Doublewrite buffer created
InnoDB: Creating foreign key constraint system tables
InnoDB: Foreign key constraint system tables created
090613 10:19:39 InnoDB: Started; log sequence number 0 0
090613 10:19:39 [Note] C:\www\mysql\bin\mysqld-nt: ready for connections.
再刪除這三個文件,加了skip-innodb后,啟動日志:
引用
090613 10:30:12 [Note] C:\www\mysql\bin\mysqld-nt: Normal shutdown
090613 10:30:12 [Note] C:\www\mysql\bin\mysqld-nt: Shutdown complete
090613 10:30:17 [Note] C:\www\mysql\bin\mysqld-nt: ready for connections.
Version: '5.0.45' socket: '' port: 3306 Source distribution
那三個文件就不會自動產生了。
MYSQL無法啟動提示: Default storage engine (InnoDB) is not available的解決方法
2019-11-18 15:09MYSQL教程網 Mysql
自己用的MYSQL都是用MYISAM數據庫,還沒涉及到需要INNODB,因此打算直接不加載INNODB引擎。
延伸 · 閱讀
- 2022-03-02MySQL的InnoDB存儲引擎的數據頁結構詳解
- 2021-12-08MySQL Innodb索引機制詳細介紹
- 2021-11-17MySQL InnoDB 事務鎖源碼分析
- 2021-11-15不知道 Insert Buffer 的請舉手
- 2021-11-09庖丁解 InnoDB 之 Undolog
- 2021-11-09MyISAM與InnoDB索引實現對比詳解
- Mysql
解決重置Mysql root用戶賬號密碼問題
這篇文章主要介紹了解決重置Mysql root用戶賬號密碼問題,本文給大家介紹的非常詳細,具有一定的參考借鑒價值,需要的朋友可以參考下...
- Mysql
MySQL server has gone away錯誤提示解決方法
今天遇到類似的情景,MySQL只是冷冷的說:MySQL server has gone away。 ...
- Mysql
幾種MySQL中的聯接查詢操作方法總結
這篇文章主要介紹了幾種MySQL中的聯接查詢操作方法總結,文中包括一些代碼舉例講解,需要的朋友可以參考下 ...
- Mysql
Centos7下使用yum安裝mysql數據庫的詳細教程(增強版)
這篇文章主要介紹了Centos7下使用yum安裝mysql數據庫的詳細教程(增強版),非常不錯,具有參考借鑒價值,需要的朋友可以參考下 ...
- Mysql
MySQL鎖的知識點總結
在本篇文章里小編給大家整理了關于MySQL鎖的知識點總結以及實例內容,需要的朋友們學習下。...
- Mysql
MySQL之Field‘***’doesn’t have a default value錯誤解決辦法
這篇文章主要介紹了MySQL之Field‘***’doesn’t have a default value錯誤解決辦法,需要的朋友可以參考下 ...
- Mysql
MySQL全文索引、聯合索引、like查詢、json查詢速度哪個快
這篇文章主要介紹了MySQL全文索引、聯合索引、like查詢、json查詢速度大比拼,通過實例代碼截圖的形式給大家介紹的非常詳細,具有一定的參考借鑒價值...
- Mysql
MySQL 查詢速度慢與性能差的原因與解決方法
隨著網站數據量與訪問量的增加,MySQL 查詢速度慢與性能差的問題就日漸明顯,這里為大家分享一下解決方法,需要的朋友可以參考下...