方法步骤:

1、用SSH登录mysql,使用命令查看mysql的默认编码。

    命令:show variables like 'character_set_%';

2、进入配置文件修改配置内容,执行命令:vi /etc/my.cnf

3、修改配置文件的内容,在[mysqld]结束位置添加:character_set_server=utf8

4、重新启动mysql服务。

    停止命令:systemctl stop mysqld.service

    启动命令:systemctl start mysqld.service

相关文章:

  • 2021-10-16
  • 2021-11-20
  • 2021-08-08
  • 2021-11-14
  • 2021-10-25
  • 2021-07-24
  • 2021-05-18
  • 2021-04-11
猜你喜欢
  • 2021-11-20
  • 2021-06-11
  • 2021-09-25
  • 2021-11-30
  • 2021-11-30
  • 2021-12-08
  • 2021-11-02
  • 2021-07-31
相关资源
相似解决方案