微擎出错信息:

Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[HY000] [2054] Server sent charset unknown to the client. Please, report to the developers' in /data/backup/weifang/framework/class/db.class.php:55 Stack trace: #0 /data/backup/weifang/framework/class/db.class.php(55): PDO->__construct('mysql:dbname=we...', 'root', 'gPYD3t24', Array) #1 /data/backup/weifang/framework/class/db.class.php(25): DB->connect(Array) #2 /data/backup/weifang/framework/function/pdo.func.php(19): DB->__construct(Array) #3 /data/backup/weifang/framework/function/pdo.func.php(65): pdo() #4 /data/backup/weifang/framework/function/cache.mysql.func.php(9): pdo_getcolumn('core_cache', Array, 'value') #5 /data/backup/weifang/framework/function/cache.func.php(39): cache_read('setting') #6 /data/backup/weifang/framework/model/setting.mod.php(34): cache_load('setting') #7 /data/backup/weifang/framework/bootstrap.inc.php(129): setting_load() #8 /data/backup/weifang/index.php(6): require('/data/backup/we...') #9 {main} thrown in /data/backup/weifang/framework/class/db.class.php on line 55

换成mysql 8.0了,其默认编码修改成了utfmb4,需要修改配置文件:

[client]
default-character-set=utf8 [mysql]
default-character-set=utf8 [mysqld]
collation-server = utf8_unicode_ci
character-set-server = utf8

完毕。

PDO::__construct(): Server sent charset (255) unknown to the client. Please, report to the developers的更多相关文章

  1. PDO连接mysql8.0报PDO::__construct(): Server sent charset (255) unknown to the client. Please, report to the developers错误

    安装mysql8.0之后,尝试使用php连接mysql,总是报PDO::__construct(): Server sent charset (255) unknown to the client. ...

  2. Mac环境下PHP连接mysql提示Server sent charset (255) unknown和(HY000/2054)

    错误提示: mysqli_connect(): Server sent charset (255) unknown to the client. Please, report to the devel ...

  3. php7.3连接MySQL8.0报错 PDO::__construct(): The server requested authentication method unknown to the client [caching_sha2_password]

    报的错误: In Connection.php line : SQLSTATE[HY000] [] The server requested authentication method unknown ...

  4. Laravel - 解决连接MySQL时报"The server requested authentication method unknown to the client”错误

    2019-04-12发布:hangge阅读:934   1,问题描述 最近建了个 Laravel 项目,当配置好 MySQL 数据库进行请求时,页面报如下错误:   SQLSTATE[HY000] [ ...

  5. PHP错误:SQLSTATE[HY000] [2054] The server requested authentication method unknown to the client

    使用PHP连接MySQL 8的时候,可能会发生如标题所示的错误: SQLSTATE[HY000] [2054] The server requested authentication method u ...

  6. mysql 8.0 错误The server requested authentication method unknown to the client

    mysql 安装了最新版本8.0.11后创建用户并授权后,授权的用户连接数据库提示 The server requested authentication method unknown to the ...

  7. mysql8.0:SQLSTATE[HY000] [2054] The server requested authentication method unknown to the client

    忽然注意到的情况: 2018/7/19至2018/9/13之间发布的7.1.20.7.1.21.7.1.22和7.2.8.7.2.9.7.2.10这六个版本提供的对caching_sha2_passw ...

  8. Warning: mysqli_connect(): The server requested authentication method unknown to the client [caching_sha2_password]报错解决方法

    错误: 解决方法:

  9. PHP Warning: mysqli_connect(): The server requested authentication method unknown to the client [caching_sha2_password] in /usr/local/php/CreateDB.php on line 5

    原因:php还不支持mysql8.0最新的密码加密方式 ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY ' ...

随机推荐

  1. Java 之 CSS

    1.CSS a.定义:CSS 指层叠样式表 b.意义:为了解决内容与表现分离的问题 c.特点:多个样式可层叠为一 2.用法: a.行内样式:style <span style="col ...

  2. HDU 2586 How far away ?(经典)(RMQ + 在线ST+ Tarjan离线) 【LCA】

    <题目链接> 题目大意:给你一棵带有边权的树,然后进行q次查询,每次查询输出指定两个节点之间的距离. 解题分析:本题有多重解决方法,首先,可用最短路轻易求解.若只用LCA解决本题,也有三种 ...

  3. C#Stopwatch的简单计时zz

    Stopwatch 类 命名空间:System.Diagnostics.Stopwatch 实例化:Stopwatch getTime=new Stopwatch(); 开始计时:getTime.St ...

  4. bootstrap之FONTAWESOME 图标

    终于暂时的结束了winform迎来了B/S的项目,这个需要我们自己写前端页面,要用bootstrap搭页面,本人小白,正在慢慢摸索中,主要记录遇到的问题,及解决办法. 第一个,显示时间选择的控件.我在 ...

  5. [APIO2012]派遣

    [APIO2012]派遣 题目大意: 给定一棵\(n(n\le10^5)\)个结点的有根树,每个点有代价\(c_i\)和权值\(l_i\),要求你选定一个结点\(k\),并在对应的子树中选取一个点集\ ...

  6. 老毛桃UEFI版u盘启动盘

    使用老毛桃制作UEFI启动盘 下载UEFI版本启动盘制作工具,打开官方网站http://www.laomaotao.org,当前显示页面右下下载UEFI版本.文章写作时最新版本为9.3. 使用教程见: ...

  7. pythonweb服务器编程(二)

    Web静态服务器-1-显示固定的页面 #coding=utf-8 import socket from multiprocessing import Process def handleClient( ...

  8. csrf 跨站请求伪造相关以及django的中间件

    django为用户实现防止跨站请求伪造的功能,通过中间件 django.middleware.csrf.CsrfViewMiddleware来完成. 1.django中常用的中间件? - proces ...

  9. Vue(六)过滤器

    1. 简介 用来过滤模型数据,在显示之前进行数据处理和筛选 语法:{{ data | filter1(参数) | filter2(参数)}} 2. 关于内置过滤器 vue1.0中内置许多过滤器,如:c ...

  10. es6学习笔记一:迭代器和for-of循环

    我们如何遍历一个数组呢?在20年前,我们是这样遍历一个数组的: var myArr = []; for (var i = 0; i < arr.length; i++) { console.lo ...