MySQL8,新增data dictionary,數據初始化的時候在Linux下默認使用lower_case_table_names=0的參數,數據庫啟動的時候,讀取/etc/my.cnf中的值,如果/etc/my.cnf中的值與數據庫初始化時的值不一樣,則會報如下錯誤
[ERROR] [MY-011087] [Server] Different lower_case_table_names settings for server ('1') and data dictionary ('0').
MySQL官方提供的rpm包,默認禁用
lower_case_table_names=0
--官方解釋:
After initialization, is is not allowed to change this setting.So "lower_case_table_names" needs to be set together with --initialize .
此參數需數據庫初始化的值和啟動是的值需相等
重新初始化
mysqld --user=mysql --lower_case_table_names=1 --initialize-insecure --basedir=/usr/local/mysql --datadir=/data/mysql