服务器的日志一直报Packet for query is too large (7632997 > 4194304). You can change this value on the server by setting the max_allowed_packet' variable.的解决方法
服务器的日志一直报Packet for query is too large (7632997 > 4194304). You can change this value on the server by setting the max_allowed_packet' variable.的解决方法
最近服务器上的项目老是频繁的就崩掉了,重启之后过了一晚第二天来就又挂了,查看tomcat的日志有报内存溢出的错误,还有报Packet for query is too large (7632997 > 4194304). You can change this value on the server by
setting the max_allowed_packet' variable.错误。服务上的数据库是mysql。然后查了一下资料是MySQL的一个系统参数问题:max_allowed_packet,其默认值为1048576(1M),查询:show VARIABLES like '%max_allowed_packet%';
修改此变量的值:MySQL安装目录下的my.ini文件中的[mysqld]段中的"max_allowed_packet = 1M",如更改为4M(或更大,如果没有这行内容,增加一行),保存,重起MySQL服务。现在可以load大于1M的文件了。
注意)如果服务器上的mysql安装目录下找不到my.ini文件,可能是被隐藏,把它显示出来就行了。
原文博客的链接地址:https://cnblogs.com/qzf/
服务器的日志一直报Packet for query is too large (7632997 > 4194304). You can change this value on the server by setting the max_allowed_packet' variable.的解决方法的更多相关文章
- MYSQL Packet for query is too large (12054240 > 4194304). You can change this value on the server by setting the max_allowed_packet' variable.
MYSQL Packet for query is too large (12054240 > 4194304). You can change this value on the server ...
- 问题: Packet for query is too large (1786 > 1024). You can change this value on the server by setting the max_allowed_packet' variable.
错误描述: 今天在手机端查看之前上线的项目时,突然报了下面的错误.再之后用电脑登陆,其他设备登陆都一直报这个错误. 错误信息: ### Error querying database. Cause: ...
- Cause: com.mysql.jdbc.PacketTooBigException: Packet for query is too large (16944839 > 16777216). You can change this value on the server by setting the max_allowed_packet' variable.
今天发现task微服务的error日志报如下错误: Cause: com.mysql.jdbc.PacketTooBigException: Packet for query is too large ...
- mysql Packet for query is too large (2036 > 1024). You can change this value on the server by setting the max_allowed_packet' variable.
解决方法: 打开控制台,输入下面语句,执行 set global max_allowed_packet = 20*1024*1024; 网上说要重启 mysql server, 我是执行完后不用重启就 ...
- Linux服务器上日志报com.mysql.jdbc.PacketTooBigException: Packet for query is too large (1783 > 1024). You can change this value on the server by setting the max_allowed_packet' variable.
在做查询数据库操作时,报了以上错误,还有out of memery heap hacp ,原因是MySQL的max_allowed_packet设置过小引起的,我一开始设置的是1M,后来改为了20M ...
- Mysql报错:Packet for query is too large (1121604 > 1048576).You can change this value on the server by setting the max_allowed_packet variable
看错误信息,发现1048576个字节,正好是1*1024*1024byte,也就是1Mb. 这正是mysql默认的max_allowed_packet值. 使用sql语句: show VARIABLE ...
- Packet for query is too large (1660 > 1024). You can change this value on the server by setting the max_allowed_packet' variable.
原因是mysql 默认允许的 数据报包 是 1M 设置大一些就可以了 centos 下面 /ect/my.cnf 文件里面 加入或者修改 下面的参数 [mysqld] max_allowed_pa ...
- com.mysql.jdbc.PacketTooBigException: Packet for query is too large (1680 > 1024). You can change this value on the server by setting the max_allowed_packet' variable.
这个错误是由于mysql的一个系统参数max_allowed_packet设置的值过小引起的 解决这个错误的方法就是修改这个参数的值, linux系统中我们在etc目录下找到my.cnf这个文件,打开 ...
- MySQL5中大数据错误:Packet for query is too large (****** > ******). You can change this value on the server by setting the max_allowed_packet' variable.;
使用的MySQL数据库版本:5.5 插入或更新字段有大数据时(大于1M),会出现如下错误: ### Cause: com.mysql.jdbc.PacketTooBigException: Packe ...
随机推荐
- JAVA Spring 事物 ( 已转账为例 ) 基于 AOP 注解
<一> 配置为文件 <?xml version="1.0" encoding="UTF-8"?> <beans xmlns=&qu ...
- Java实现邮箱发送
- HTTPS 路径配置
1: 首先安装 fiddlercertmaker.exe 文件 2:Tools -> HTTPS 3: Connections 勾中Allow remote computer to ...
- objective C, parse json时注意事项
例: dict为从API请求返回的json调用 NSJSONSerialization JSONObjectWithData:方法得到的NSDictionary实例. 当执行以下语句时linkStri ...
- 面向对象三大特性一一封装(encapsulation)
为什么要封装? 我们看电视,只要按一下开关和换台就行了.有必要了解电视的内部结构吗?有必要了解显像管吗? 封装是为了隐藏对象内部的复杂性,只对外公开简单的接口.便于外界调用,从而提高系统的可扩展性,可 ...
- IntelliJ IDEA教程
http://www.jetbrains.com/help/idea/meet-intellij-idea.html
- 201671010140. 2016-2017-2 《Java程序设计》java学习第四周
java学习第四周体会 本周,与前几周不同的是,老师没有进行课堂测试,而是上了一节课,回顾与总结了之前三周所学的知识,也是因为这节课,我注意到了之前学习中忽略的一些细节,和之前学习方法 ...
- Python 列表表达式 ,迭代器(2) Yield
.yield 暂存为list def max_generator(numbers): current_max = for i in numbers: current_max = max(i, curr ...
- 好用的模板引擎NVelocity
CastleNVelocity-1.1.1,使用方法: 把dll放到项目中,添加引用,修改配置的文件夹以及数据模型,最后在逻辑代码中调用即可. 封装到CommonHelper.cs using Sys ...
- 2014年可用的TRACKER服务器大全
udp://tracker.openbittorrent.com:80/announceudp://tracker.publicbt.com:80/announcehttp://pubt.net:27 ...