Bug #81458 Packet for query is too large (1094 > 1024)
Submitted: 17 May 2016 8:48 Modified: 17 May 2016 12:20
Reporter: purna chandra Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Server Severity:S2 (Serious)
Version:5.7.12 OS:Microsoft Windows (Windows 2008 Server R2 Enterprise)
Assigned to: CPU Architecture:Any

[17 May 2016 8:48] purna chandra
Description:
2016 Apr 27 19:13:15 ERROR [http-apr-8080-exec-9] SqlExceptionHelper | :::: | Packet for query is too large (1214 > 1024). You can change this value on the server by setting the max_allowed_packet' variable.
2016 Apr 27 19:13:15 ERROR [http-apr-8080-exec-9] ServiceHandler | :::: | Error while processing request for requestType=campaignP0
org.hibernate.exception.GenericJDBCException: could not extract ResultSet
	at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:47)
	at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:111)
	at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:97)
	at org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.extract(ResultSetReturnImpl.java:79)
	at org.hibernate.loader.Loader.getResultSet(Loader.java:2115)
	at org.hibernate.loader.Loader.executeQueryStatement(Loader.java:1898)
	at org.hibernate.loader.Loader.executeQueryStatement(Loader.java:1874)

when executed the following command on terminal it shows the max allowed packet size value as 32MB which is the configured value in the config file

SHOW VARIABLES LIKE 'max_allowed_packet';
+--------------------+----------+
| Variable_name      | Value    |
+--------------------+----------+
| max_allowed_packet |1073741824|
+--------------------+----------+
1 row in set (0.00 sec)

in /etc/mysql/my.cnf I have the config un [mysqld] as below

[mysqld]
/** other configs **/
max_allowed_packet      = 64M

Using jdbc:mysql://localhost:3306/hygiene_db?useSSL=false&useUnicode=true&characterEncoding=utf-8&maxAllowedPacket=67108864 as connection URL does not help too.

Previously, we were using 5.7.11 and upgrading it to latest version didn't helped.

Once the mysql server is restarted this problem goes away but appear again within few days.

How to repeat:
It would re-appear every few days.
[17 May 2016 11:25] Peter Laursen
Similar reports:
https://bugs.mysql.com/bug.php?id=76177
https://bugs.mysql.com/bug.php?id=80622

-- Peter
-- not a MySQL/Oracle person
[17 May 2016 12:20] Chiranjeevi Battula
Hello purna chandra,

Thank you for the bug report.
This is most likely duplicate of Bug #76816, please see Bug #76816.

Thanks,
Chiranjeevi.