The FreeBSD Diary

The FreeBSD Diary (TM)

Providing practical examples since 1998

If you buy from Amazon USA, please support us by using this link.
Scripts / handy tips
 New Topic  |  Go to Top  |  Go to Topic  |  Search  |  Log In   Previous Message  |  Next Message 
 Re: MySQL? XML? mysqldump?
Author: Dan 
Date:   21-11-06 16:59

csinclair wrote:

> <code snippet>
> #!/bin/csh
> #www/data backup
> tar -cf - /usr/local/www/data-dist/* | gzip -c >
> ~/bak/$1_www_data.tar.gz

What is this backing up? The websites? OK.

> #mysql db backup
> sqldump --user=root --password=******** wikidb >
> ~/bak/$1.mysql.dump

> tar -cf - ~/bak/$1.mysql.dump | gzip -c >
> ~/bak/$1_mysql_dump.tar.gz
> rm ~/bal/$1.mysql.dump

> </code snippet>

> As you can clearly see I'm not using the xml option, I would
> if I thought it would be helpful, please explain.
> Also, what about all of my graphic images on the server as
> well, I've been tar.gz'ing them with the script as well, but
> I'm not too sure how the images will fare in the
> tarring/untarring as well as how to automate or ease the
> transition when moving the Wiki database, pictures and all.
> Any tips or pointers on this topic are appreciated as I'll
> have to use this soon in the real world.

Have you tested it? Reverse the process and import the data you backed up. Test it.


 Reply To This Message  |  Forum List  |  Flat View   Newer Topic  |  Older Topic 

 Topics Author  Date
 MySQL? XML? mysqldump?   new
Dan 27-09-06 18:32 
 Re: MySQL? XML? mysqldump?   new
csinclair 21-11-06 16:40 
 Re: MySQL? XML? mysqldump?   new
Dan 21-11-06 16:55 
 Re: MySQL? XML? mysqldump?   new
Dan 21-11-06 16:59 
 Re: MySQL? XML? mysqldump?   new
csinclair 23-11-06 01:11 
 Re: MySQL? XML? mysqldump?   new
Dan 23-11-06 01:21 

 User Login
 User Name:
 Remember my login:
 Forgot Your Password?
Enter your email address or user name below and a new password will be sent to the email address associated with your profile.
How to get the most out of the forum