[Solved] MYSQL:1153 Got a packet bigger than ‘max_allowed_packet’ bytes

Backup restore or data import error 1153: Got a packet bigger than’max_allowed_packet’bytes problem

There are 2 solutions to this problem:

1. Temporary modification:

mysql>set global max_allowed_packet=524288000; #修改 512M

2. To modify my.cnf (my.ini under windows), mysql needs to be restarted.
Add a sentence in the [MySQLd] section (if it exists, adjust its value):
max_allowed_packet=256M (adjust the value according to the actual situation)

You can use the command:

show VARIABLES like '%max_allowed_packet%’;

Check whether the modification is successful!


Similar Posts: