List:General Discussion« Previous MessageNext Message »
From:Tim Gustafson Date:August 29 2005 1:49pm
Subject:RE: mysqldump: Error 2013
View as plain text  
Shawn,

Thanks.  I should have included the switches I was using to make the
backup.

I'm using "--opt --quote-names", and according to the manual, "--opt"
includes "--quick".

Tim Gustafson
MEI Technology Consulting, Inc
tjg@stripped
(516) 379-0001 Office
(516) 908-4185 Fax
http://www.meitech.com/ 



-----Original Message-----
From: SGreen@stripped [mailto:SGreen@stripped]
Sent: Monday, August 29, 2005 9:35 AM
To: Gustafson, Tim
Cc: mysql@stripped
Subject: Re: mysqldump: Error 2013




"Gustafson, Tim" <tjg@stripped> wrote on 08/29/2005 09:24:36 AM:

> Hello
> 
> I am using mysqldump to backup my entire database (about 40GB total)
> each night.  I dump each table separetly, so that if mysqldump crashes
> in the middle somewhere, the rest of the database still gets backed
up.
> 
> Most of the tables are fairly small.  About 20GB of the database is
> spread across more than a hundred tables.  However, one table is very
> large - it accounts for the other 20GB of the dataset.
> 
> When backing up this table, I get this error message every night:
> 
> /usr/local/bin/mysqldump: Error 2013: Lost connection to MySQL server
> during query when dumping table `DocumentVariants` at row: 13456
> 
> The table actually has 94,916 rows in it.  There are no entries in the
> mySQL server log and nothing in /var/log/messages.  There is plenty of
> disk space available on the backup drive.  The file is about 4.5GB
when
> this happens, which is about 1/5 of the total table size.  The table
> itself contains a lot of binary data in a longblob field, in case that
> makes any difference.  wait_timeout on my server is set to 86400, and
> the whole backup takes less than an hour, so the timeout is not the
> problem.
> 
> Has anyone else had similar problems?  Can anyone shed some light on
how
> to successfully back up this database?
> 
> Thanks!
> 
> Tim Gustafson
> MEI Technology Consulting, Inc
> tjg@stripped
> (516) 379-0001 Office
> (516) 908-4185 Fax
> http://www.meitech.com/ 

The one thing I can think of is to check that you are not trying to
buffer your output. Use the "quick" option when you start mysqldump (to
skip memory buffering the dump file) and write the data straight to disk
as it arrives. With a 20GB file it will be very easy to exceed available
system memory allocation limits. With the buffering turned off, you
shouldn't hit that limit. 

Shawn Green
Database Administrator
Unimin Corporation - Spruce Pine 

Attachment: [application/x-pkcs7-signature] smime.p7s
Thread
mysqldump: Error 2013Tim Gustafson29 Aug
  • Re: mysqldump: Error 2013SGreen29 Aug
  • Re: mysqldump: Error 2013Hassan Schroeder29 Aug
  • Re: mysqldump: Error 2013Gleb Paharenko29 Aug
  • re:mysqldump: Error 2013(christophe charron)7 Sep
    • Re: re:mysqldump: Error 2013Gleb Paharenko7 Sep
RE: mysqldump: Error 2013Tim Gustafson29 Aug
RE: mysqldump: Error 2013Tim Gustafson29 Aug
  • Re: mysqldump: Error 2013Hassan Schroeder29 Aug
Re: mysqldump: Error 2013Michael Stassen29 Aug
RE: mysqldump: Error 2013Tim Gustafson29 Aug
RE: mysqldump: Error 2013Tim Gustafson30 Aug
RE: mysqldump: Error 2013Tim Gustafson2 Sep