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.
Dan
--
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
website: http://www.nusconsulting.com.au