天天看點

Error message file '/usr/share/mysql/english/errmsg.sys' 實為吾之愚見,望諸君酌之!聞過則喜,與君共勉

作者:手辨

實為吾之愚見,望諸君酌之!聞過則喜,與君共勉

前幾天無意間遇到了一個資料庫啟動問題,說一下自己的解決辦法 

1.問題描述:

資料庫啟動出現如下錯誤:

180712 23:33:48 [ERROR] Error message file

'/usr/share/mysql/english

/errmsg.sys' had only 641 error messages,but it should contain at least

 728 error messages.Check that the above file is the right version for this

program!

180712 23:33:48 [Note] Plugin 'FEDERATED' is disabled.

180712 23:33:48 InnoDB: The InnoDB memory heap is disabled

180712 23:33:48 InnoDB: Mutexes and rw_locks use GCC atomic

builtins

180712 23:33:48 InnoDB: Compressed tables use zlib 1.2.3

180712 23:33:48 InnoDB: Using Linux native AIO

180712 23:33:48 InnoDB: Initializing buffer pool, size =

128.0M

180712 23:33:48 InnoDB: Completed initialization of buffer

pool

180712 23:33:48 InnoDB: highest supported file format is

Barracuda.

InnoDB: The user has set SRV_FORCE_NO_LOG_REDO on

InnoDB: Skipping log redo

180712 23:33:48 InnoDB: Waiting for the background threads

to start

180712 23:33:49 InnoDB: 5.5.52 started; log sequence number

180712 23:33:49 InnoDB: !!! innodb_force_recovery is set to

6 !!!

180712 23:33:49 [ERROR] Aborting

180712 23:33:49 InnoDB: Starting shutdown...

180712 23:33:50 InnoDB: Shutdown completed; log sequence

number 8204

180712 23:33:50 [Note]

2.問題分析:

這個日志裡,沒有兩個錯誤,第一個是:

180712 23:33:48 [ERROR] Error message file '/usr/share/mysql/english/errmsg.sys'

had only 641 error messages,but it should contain at least 728 error messages.

第二個是:

開始因為第一個錯誤和第二個錯誤隔得很遠,并沒有在意,在排查了其他方面都沒有問題後,

考慮原因是:第二個錯誤是由第一個錯誤引起,需要先處理下第一個錯誤

問題原因:

這類情況一般是一台主機上安裝了其他版本的mysql産生的,很大可能是第一個的errmsg.sys

檔案被後面版本的替代,這裡的錯誤是指:errmsg.sys檔案應該有

728個錯誤資訊,但是目前

隻有641個,與目前的程式版本無法對應上

問題處理:

我是下載下傳與目前的版本相對應的二進制檔案,解壓後,從對應的目錄下解壓出來errmsg.sys檔案,

替換掉後啟動,如下 

Error message file '/usr/share/mysql/english/errmsg.sys' 實為吾之愚見,望諸君酌之!聞過則喜,與君共勉