【IT笔记】centos7.x下yum安装Mysql5.7

2019-03-22  本文已影响0人  陆拾遗

备注:

sudo rpm -Uvh http://dev.mysql.com/get/mysql57-community-release-el7-7.noarch.rpm
sudo yum install mysql-community-server 
service mysqld start

其它说明:


MySQL5.7导入数据报错ERROR 1067 (42000) at line 1015: Invalid default value for 'service_time'

解决办法:
修改my.cnf,
[mysqld] 下面添加
sql_mode=STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION
explicit_defaults_for_timestamp=1

上一篇下一篇

猜你喜欢

热点阅读