解决Docker容器中Mysql中文乱码问题
进入容器,修改/etc/mysql/my.cnf添加如下配置[client]port = 3306socket = /var/lib/mysql/mysql.sockdefault-character-set=utf8[mysqld]port = 3306socket = /var/lib/mysql/mysql.sockcharacter-set-server=utf8[mysql]no-aut
·
进入容器,修改/etc/mysql/my.cnf
添加如下配置
[client]
port = 3306
socket = /var/lib/mysql/mysql.sock
default-character-set=utf8
[mysqld]
port = 3306
socket = /var/lib/mysql/mysql.sock
character-set-server=utf8
[mysql]
no-auto-rehash
default-character-set=utf8
重启容器
更多推荐
已为社区贡献2条内容
所有评论(0)