1

Getting the following error:

ERROR 2006 (HY000) at line 530: MySQL server has gone away

Which I get after running the following from the MySQL (5.1.53-community) command line:

CREATE DATABASE restoredb;

then this from the Windows 7 system command line:

mysql -u root -p restoredb < "C:\restoredb.sql"

I've tried another database restore using another file and the MySQL restore command works fine.

Questions, feedback, requests -- just comment, thanks!!

1
  • It means you lost your connection to the server. Perhaps you left the connection open too long without sending anything and it timed out. Perhaps you tried to send a query that was so large it exceeded the timeout or maximum query size limit. Check MySQL's error log for any hints. Feb 24 '11 at 20:54
2

Put this in your my.ini (Win) or my.cnf (Linux)

If running as a service, put under [mysqld]

[mysqld]
max_allowed_packet=32M
2
  • @ed209: +1 thanks for posting, so "Put this in your my.ini" -- what is "this"? Meaning the code provided only appears to be for "If running as a service, put under" -- thanks!
    – blunders
    Feb 25 '11 at 0:09
  • Worked, only issue I ran into was related to Windows 7, which I posted posted as a question, then answer here: serverfault.com/questions/240246/…
    – blunders
    Feb 25 '11 at 13:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.