2013-08-26 75 views
4

我一直在使用MAMP安裝幾個星期,現在當我啓動它時,它不會啓動。沒有mysql進程正在運行,所以我檢查錯誤日誌,顯示下面當我啓動服務器:MAMP Mysql錯誤 - 無法打開日誌

130826 14:19:55 mysqld_safe Starting mysqld daemon with databases from /Applications/MAMP/db/mysql 
130826 14:19:55 [Warning] You have forced lower_case_table_names to 0 through a command-line option, even though your file system '/Applications/MAMP/db/mysql/' is case insensitive. This means that you can corrupt a MyISAM table by accessing it with different cases. You should consider changing lower_case_table_names to 1 or 2 
130826 14:19:55 [Warning] One can only use the --user switch if running as root 

130826 14:19:55 [Note] Plugin 'FEDERATED' is disabled. 
130826 14:19:55 InnoDB: The InnoDB memory heap is disabled 
130826 14:19:55 InnoDB: Mutexes and rw_locks use GCC atomic builtins 
130826 14:19:55 InnoDB: Compressed tables use zlib 1.2.3 
130826 14:19:55 InnoDB: Initializing buffer pool, size = 128.0M 
130826 14:19:55 InnoDB: Completed initialization of buffer pool 
130826 14:19:55 InnoDB: highest supported file format is Barracuda. 
130826 14:19:55 InnoDB: Waiting for the background threads to start 
130826 14:19:56 InnoDB: 1.1.8 started; log sequence number 4057202289 
/Applications/MAMP/Library/bin/mysqld: File './mysql-bin.000025' not found (Errcode: 2) 
130826 14:19:56 [ERROR] Failed to open log (file './mysql-bin.000025', errno 2) 
130826 14:19:56 [ERROR] Could not open log file 
130826 14:19:56 [ERROR] Can't init tc log 
130826 14:19:56 [ERROR] Aborting 

130826 14:19:56 InnoDB: Starting shutdown... 
130826 14:19:57 InnoDB: Shutdown completed; log sequence number 4057202289 
130826 14:19:57 [Note] /Applications/MAMP/Library/bin/mysqld: Shutdown complete 

130826 14:19:57 mysqld_safe mysqld from pid file /Applications/MAMP/tmp/mysql/mysql.pid ended 

所以,很明顯,有一定的日誌文件無法找到,但我不知道爲什麼會發生,或如何解決它。

回答

9

看來,其中一個二進制日誌文件Applications/MAMP/db/mysql/mysql-bin.000025被損壞或刪除(它不再存在,我沒有手動刪除它)。

做一些研究和尋找this文章後,我能夠通過導航到/Applications/MAMP/db/mysql和手動編輯 mysql-bin.index不再包括丟失的日誌文件,以解決這個問題。

我還是有點困惑最初導致這個問題的原因,因爲我正常關閉我的MAMP服務器並且從未觸及過二進制日誌文件...