List:General Discussion« Previous MessageNext Message »
From:Michael Widenius Date:February 15 2000 5:55am
Subject:Re: Backup db
View as plain text  
Hi!

>>>>> "sasha" == sasha  <sasha@stripped> writes:

sasha> Kristian Hoffmann wrote:
>> 
>> I'm not sure how mysql handles it internally.  You'd have to ask one of
>> the developers or RTFS.  You could do the dump, store it in a directory or
>> incramentally back it up to any rw media, and then "delete from tbname".
>> That actually deletes the file the table is stored in and recreates it so
>> it is very fast.  "delete from tbname where ..." takes much longer.  Then
>> you have records that you can store on a shelf somewhere and a db that's
>> not enourmous.
>> 
>> Slightly off topic, there's another cool kernel patch available on
>> freshmeat that impliments transparent gzipping of files.  The kernel
>> compress/decompresses the files on the fly so programs like mysqld don't
>> know the difference.  If you have a fast server, this could be a cool and
>> simple way of keeping those enourmous databases in check.
>> 
>> -Kristian
>> 

sasha> I've taken a brief look at the sources of mysqldump -- it does not seem to lock
sasha> the tables while dumping - maybe we should add this as a special option. In any
sasha> case, if you have "transactions", and you do them properly by locking the
sasha> appropriate tables in your code, mysqldump will not be able to read the table
sasha> until the "transaction" is complete.

mysqldump --lock-tables or
mysqldump --opt

will lock the tables specified on the command line.

Regards,
Monty
Thread
Installing MySql on LinuxBarry On Linux13 Feb
  • Re: Installing MySql on LinuxKristian Hoffmann13 Feb
    • Backup dbDave VanHorn13 Feb
      • MySQL - MS SQL Server 7 - eCommerce Solutionszarlengo13 Feb
      • Re: Backup dbThimble Smith14 Feb
    • Re: Backup dbDave VanHorn14 Feb
      • RE: Backup dbAndy Frankford14 Feb
        • Re: Backup dbDave VanHorn14 Feb
        • RE: Backup dbKristian Hoffmann14 Feb
          • Re: Backup dbDave VanHorn14 Feb
            • Re: Backup dbKristian Hoffmann14 Feb
              • Re: Backup dbDave VanHorn14 Feb
                • Re: Backup dbKristian Hoffmann14 Feb
                  • Re: Backup dbDave VanHorn14 Feb
                    • Re: Backup dbKristian Hoffmann14 Feb
                      • Re: Backup dbsasha14 Feb
                        • Re: Backup dbTim Bunce14 Feb
                        • Perl support in 3.22.32Robert Alexander14 Feb
                        • Re: Backup dbMichael Widenius15 Feb
                  • Radius -> MySQL [was Re: Backup db]Michael Bacarella14 Feb
                    • Re: Radius -> MySQL [was Re: Backup db]Kristian Hoffmann14 Feb
          • RE: Backup dbPatrick Goetz14 Feb
      • RE: Backup dbDavid Adams14 Feb
    • Re: MySQL - MS SQL Server 7 - eCommerce Solutionssasha14 Feb
    • Re: MySQL - MS SQL Server 7 - eCommerce SolutionsJames Lyon14 Feb
      • Re: MySQL - MS SQL Server 7 - eCommerce SolutionsMichael Bacarella14 Feb