Starting MySQL. ERROR! でMariaDBが起動しない

CentOS6.6でMySQL5.6からMariaDB10.1.4にアップデートした話」を参考にMysqlをMariaDBに更新し、MariaDBを起動しようとしたんだけど、

Starting MySQL. ERROR!

と表示されて、MariaDBが起動しない。
What to Do if MariaDB Doesn’t Start」を見ると/var/lib/mysql/以下に「ホスト名.err」というファイルがあるということなので、見てみると、以下のようなエラーが出力されていました。

2016-03-07 14:14:41 140509357565984 [ERROR] InnoDB: auto-extending data file ./ibdata1 is of a different size 640 pages (rounded down to MB) than specified in the .cnf file: initial 768 pages, max 0 (relevant if non-zero) pages!
2016-03-07 14:14:41 140509357565984 [ERROR] InnoDB: Could not open or create the system tablespace. If you tried to add new data files to the system tablespace, and it failed here, you should now edit innodb_data_file_path in my.cnf back to what it was, and remove the new ibdata files InnoDB created in this failed attempt. InnoDB only wrote those files full of zeros, but did not yet use them in any way. But be careful: do not remove old data files which contain your precious data!
2016-03-07 14:14:41 140509357565984 [ERROR] Plugin 'InnoDB' init function returned error.
2016-03-07 14:14:41 140509357565984 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2016-03-07 14:14:41 140509357565984 [Note] Plugin 'FEEDBACK' is disabled.
2016-03-07 14:14:41 140509357565984 [ERROR] Unknown/unsupported storage engine: InnoDB
2016-03-07 14:14:41 140509357565984 [ERROR] Aborting

自動拡張データ用のファイルということなので、/var/lib/mysql/ibdata1を/var/lib/mysql/ibdata1.bakにリネームして起動するも以下のようなエラーがでて立ち上がらない。

2016-03-07 14:24:37 140248190801952 [ERROR] InnoDB: Cannot create ./ib_logfile1
2016-03-07 14:29:13 139859024570400 [ERROR] InnoDB: Cannot create ./ib_logfile101

結局、ibdata1、ib_logfile1、ib_logfile101をリネームすると起動することができました。

投稿日:
カテゴリー: centosdb