[thelist] MySQL - Got a packet bigger than 'max_allowed_packet' bytes

Brady Mitchell mydarb at gmail.com
Sat Mar 20 00:30:47 CDT 2010


On Fri, Mar 19, 2010 at 4:46 PM, Bob Meetin <bobm at dottedi.biz> wrote:
> I am moving a database to a new webhost, created a very large dump.sql file
> (had to use the GUI PHPMyAdmin), but am having trouble restoring it at the
> new location.  Am using a restore query like this via shell prompt:
>
> % mysql -u$username -p$password $database < dump.sql
>
> This results in: ERROR 1153 (08S01) at line 72: Got a packet bigger than
> 'max_allowed_packet' bytes

When you exported the data from phpMyAdmin, did you use extended
inserts? Try exporting the data again without the extended inserts
option. I've run into this same issue many times when I've exported
data with extended inserts. I recommend using complete inserts, but
not extended. It will create a larger SQL file as there will be one
query per table record, but it's much more reliable in my experience.

Brady


More information about the thelist mailing list