List:General Discussion« Previous MessageNext Message »
From:Daniel Kasak Date:January 14 2004 10:33pm
Subject:Re: why: mysqldump and mysqlimport?
View as plain text  
EP wrote:

> I am wondering:
> I can see the MySQL data files for my various databases.
> What technically prevents me from simply copying those files and using 
> copies
> - to move my database to another file structure or server
> - to back-up my current db
> Yes, I did put my finger in the electrical socket as a kid.  But only 
> several times.
A simple file copy works if:

a) No-one is accessing the database at the time, and
b) There is no database corruption

If you have database corruption, mysqldump will often be the first to 
know about it, as you're selecting all rows ( as opposed to other mysql 
clients which are selecting specific rows ). So using mysqldump and 
watching the output ( make a cron job and it'll email you the output ), 
you can catch database corruption early and have a good chance to do 
something about it, instead of simply copying corrupt files day after 
day until you finally don't have a valid backup around.


Daniel Kasak
IT Developer
NUS Consulting Group
Level 5, 77 Pacific Highway
North Sydney, NSW, Australia 2060
T: (+61) 2 9922-7676 / F: (+61) 2 9922 7989
email: dkasak@stripped

Importing a dumpfileMatthew Stuart14 Jan
  • Re: Importing a dumpfileDaniel Kasak14 Jan
  • Re: Importing a dumpfileDouglas Sims14 Jan
  • Re: Importing a dumpfileRoger Baklund14 Jan
    • why: mysqldump and mysqlimport?EP14 Jan
      • Re: why: mysqldump and mysqlimport?Dan Nelson14 Jan
      • Re: why: mysqldump and mysqlimport?Tobias Asplund14 Jan
      • Re: why: mysqldump and mysqlimport?Daniel Kasak14 Jan