MySQL Database Error: Packets larger than max_allowed_packet are not allowed - during insert
To set the max to 16MB for example, without requiring a restart, run:
SET GLOBAL max_allowed_packet = 16777216
How to fix this problem : change the value of the max_allowed_packet
variable in the configuration of your MySQL server.
How to know how much over what's allowed you are : not sure, but I would say that checking the size (in bytes) or your insert
query should give you an idea.
For more informations, you should take a look at the following section of the MySQL manual : C.5.2.10. Packet too large.