[MySQL] #1153 Got a packet bigger than 'max_allowed_packet' bytes

When I runed a 32M database file in phpmyadmin, I got this error in the screen.

#1153 - Got a packet bigger than 'max_allowed_packet' bytes

There is a good way to fix this problem. Open the my.cnf file in the mysql install path. (Because I install the lampp, so I just modify this file /opt/lampp/etc/my.cnf)

change the lines:

max_allowed_packet = 128M #as much as you want.

And then, remember to restart the mysql server.

Have fun :)

原文地址:https://www.cnblogs.com/davidhhuan/p/1803601.html