简体   繁体   English

Piwik升级到MySQL 5.7+ SQLSTATE [HY000]:常规错误:2006 MySQL服务器已消失-由插件操作引起

[英]Piwik upgrading to MySQL 5.7+ SQLSTATE[HY000]: General error: 2006 MySQL server has gone away - caused by plugin Actions

Upgrading MySQL to 5.7 on a previous working Piwik has broken it. 在先前运行的Piwik上将MySQL升级到5.7已将其破坏。 Most of the dashboard widgets now error with: 现在,大多数仪表板小部件都会出现以下错误:

Referrer Websites SQLSTATE[HY000]: General error: 2006 MySQL server has gone away - caused by plugin Actions Widget Overview SQLSTATE[HY000]: General error: 2006 MySQL server has gone away - caused by plugin Actions Referrer网站SQLSTATE [HY000]:一般错误:2006 MySQL服务器已消失-由插件操作引起的Widget概述SQLSTATE [HY000]:一般错误:2006 MySQL服务器已消失-由插件操作引起。

As per the FAQ I have increased the following parameters: 根据常见问题,我增加了以下参数:

wait_timeout=100000
max_allowed_packet=128M

Restarted and so on. 重新启动,依此类推。 Even tried re importing the database and removing the character sets as per another solution. 甚至尝试根据其他解决方案重新导入数据库并删除字符集。 Thanks for help. 感谢帮助。

This was resolved in my original github post https://github.com/piwik/piwik/issues/9419 . 这已在我的原始github帖子https://github.com/piwik/piwik/issues/9419中解决。 I'm posting the answer here to help others: The solution ended up being an issue with the character sets and an issue with the file upload scripts. 我在这里发布答案以帮助其他人:解决方案最终是字符集问题和文件上传脚本问题。

  1. MySQL 5.7.5+ has now become strict on this setting. MySQL 5.7.5+现在对此设置已变得严格。 By default this is a programdata windows directory but piwik requires the following (depending on your environment): 默认情况下,这是一个programdata Windows目录,但是piwik需要以下内容(取决于您的环境):

    secure-file-priv="xxxxxxxxxxxxx/piwik/tmp/assets" secure-file-priv =“ xxxxxxxxxxxxx / piwik / tmp / assets”

If this is not set - the real error is: 如果未设置-实际错误是:

General error: 1290 The MySQL server is running with the --secure-file-priv option so it cannot execute this statement: LOAD DATA INFILE xxxxxxxxxxxx 常规错误:1290 MySQL服务器正在使用--secure-file-priv选项运行,因此它无法执行以下语句:LOAD DATA INFILE xxxxxxxxxxxx

But of course all we can see is the 2006 gone away error...... 但是,我们当然可以看到的是2006年的错误……

  1. MySQL > 5.7+ now installs by default a utf8 character set - it appears that piwik has some problems with this according to the trace I eventually got -(yes the invalid character is really an '"x'?): MySQL> 5.7+现在默认情况下会安装utf8字符集-根据我最终得到的跟踪信息,看来piwik对此有一些问题-(是,无效字符确实是'x'吗?):

SQLSTATE[HY000]: General error: 1300 Invalid utf8 character string: '"x': SQLSTATE [HY000]:常规错误:1300无效的utf8字符串:““ x”:

In Mysql I was able to change the default "schema" piwik database to "latin1" and like magic everything worked again. 在Mysql中,我能够将默认的“ schema” piwik数据库更改为“ latin1”,并且像魔术一样,一切都可以正常工作。 This leads me to assume that converting a latin1 db over to utf8 might encounter similar issues as I did. 这使我假设将latin1 db转换为utf8可能会遇到类似的问题。 I know character sets are a mine field but I wouldn't expect to see issues going from a latin1 to utf8 dataset (as they in theory should be a subset but hey this is still possible) - the other way around yes of course there should be issues most certainly. 我知道字符集是一个雷区,但我不希望看到从latin1到utf8数据集的问题(因为理论上它们应该是一个子集,但是嘿,这仍然是可能的)-当然,相反,应该有是最肯定的问题。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 SQLSTATE [HY000]:常规错误:2006 MySQL服务器已消失,无法创建临时表 - SQLSTATE[HY000]: General error: 2006 MySQL server has gone away creating temporary table 将 Laravel 连接到 XAMPP MySQL (MariaDB) 数据库 SQLSTATE[HY000] [2006] MySQL 服务器已经消失 - Connecting Laravel to XAMPP MySQL (MariaDB) database SQLSTATE[HY000] [2006] MySQL server has gone away 几个小时后棘轮 WebSocket 连接到 mysql 数据库错误 - SQLSTATE[HY000]:一般错误:2006 MySQL 服务器已消失 - Ratchet WebSocket connection to mysql database error after few hours - SQLSTATE[HY000]: General error: 2006 MySQL server has gone away PDO例外:SQLSTATE [HY000] [2006] MySQL服务器已经消失了xampp - PDO Exception:SQLSTATE[HY000] [2006] MySQL server has gone away with xampp Doctrine\\DBAL\\Driver\\PDOException SQLSTATE[HY000] [2006] MySQL 服务器已经消失 - Doctrine\DBAL\Driver\PDOException SQLSTATE[HY000] [2006] MySQL server has gone away Symfony 3 : SQLSTATE[HY000] [2006] MySQL 服务器在更新模式期间消失了 - Symfony 3 : SQLSTATE[HY000] [2006] MySQL server has gone away during update schema HY000 2006 MySQL 服务器不见了 - HY000 2006 MySQL server has gone away 尝试连接时出现“ SQLSTATE [HY000] [2006] MySQL服务器已消失” - I am getting “SQLSTATE[HY000] [2006] MySQL server has gone away” when attempting to connect 警告:mysqli_connect(): (HY000/2006): MySQL 服务器已经消失 - Warning: mysqli_connect(): (HY000/2006): MySQL server has gone away mysqli_real_connect():(HY000 / 2006):MySQL服务器已消失 - mysqli_real_connect(): (HY000/2006): MySQL server has gone away
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM