Found option without preceding group in config file /etc/my.cnf at line 1!

mysql linux 安装过程中,初始化mysql 数据库报错,内容如下,

Found option without preceding group in config file /etc/my.cnf at line 1!,

Found option without preceding group in config file /etc/my.cnf at line 1!

 

 百度,没有找到,然后去国外网站,biying,然后在statckoverflow网站上找到了答案,地址:

https://*.com/questions/8020297/mysql-my-cnf-file-found-option-without-preceding-group

Found option without preceding group in config file /etc/my.cnf at line 1!

 

 看到这句话,如梦方醒,接下来安装,果然OK。

 

回顾下,

第一点:这里和charse 编码没有关系,我还是设置的utf8,

Found option without preceding group in config file /etc/my.cnf at line 1!

 

 第二点,网上说得Linux安装教程都是对的,都有了第一行的:   [mysqld]  ,只是我忽略了,才会有这些故事。

上一篇:ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: N


下一篇:CentOS7下如何修改mysql的数据目录