Packet for query is too large MySQL
<p>I have a tomcat app connecting to a MySQL Db / java application </p>

<p>I keep getting </p>

<p>Packet for query is too large 1080>1024 </p>

<p>I tried changing my.cnf:
in my.cnf the Max packet size is defined as 50 MB and </p>

<pre><code>socket = /var/run/mysqld/mysqld.sock
port = 3306
basedir     = /usr
datadir = /var/lib/mysql
tmpdir      = /tmp
lc-messages-dir = /usr/share/mysql
lower_case_table_names  = 1
skip-external-locking



bind-address = 0.0.0.0



key_buffer      = 16M
max_allowed_packet = 50M
thread_stack        = 192K
thread_cache_size       = 8
group_concat_max_len=100000
innodb_lock_wait_timeout=300
innodb_buffer_pool_size=22G
innodb_locks_unsafe_for_binlog = ON
innodb_additional_mem_pool_size=40M
</code></pre>

<p>I have even tried passing the Param as part of the connection string </p>

<pre><code>jdbc:mysql://serverIP:3306/dbname?maxAllowedPacket=2048000
</code></pre>

<p>to the jdbc driver - still I keep getting </p>

<p>Packet for query is too large 1080>1024 </p>

<p>This keeps coming every few hours.</p>

<p>What should I check? </p>

<p>MySQL version is 5.5 </p>

<p>Thanks for the help.</p>