[Lias] MySQL backup

Tom Doyle tom at stvincents.nsw.edu.au
Thu Jul 17 08:47:29 UTC 2003


Thanks Les,

I thought the mysqldump util only backed up the structure & not the data...

cheers,
Tom.


Quoting Les Bell <lesbell at lesbell.com.au>:

 
 Tom Doyle <tom at stvincents.nsw.edu.au> wrote:
 
 >>
 What can I schedule MySQL database backups with?
 <<
 
 How about a cron job in the middle of the night that does:
 
 mysqldump -p<password> --opt <database> | gzip -c - > <filename>.gz
 
 ? You can restore it with
 
 zcat <filename>.gz | mysql -C <database> -p<password>
 
 Nice and simple, and can be easily turned into a script that maintains
 multiple revisions of backups, etc.
 
 Best,
 
 --- Les Bell, RHCE, CISSP
 [http://www.lesbell.com.au]
 
 
 _______________________________________________
 lias mailing list
 lias at lists.linux.org.au
 http://lists.linux.org.au/listinfo/lias
 


_____________________
Tom Doyle
Network Administrator
St. Vincent's College
Potts Point
Ph: 02 9368 1611
Fx: 02 9356 2118
tom at stvincents.nsw.edu.au

-------------------------------------------------
This mail sent through IMP: http://horde.org/imp/


The contents of this email are confidential. Any unauthorised use of the contents is expressly prohibited. If you have received this email in error, please advise by telephone (reverse charges) immediately and then delete/destroy the email and any printed copies. Thankyou.



More information about the lias mailing list