Sparks,
I'm not sure why but when I try to reply to your question, Outlook Express
thinks it is a newsgroup post, not an email, and insists on knowing the
newsgroup name to which I should send my answer. Obviously, that is bogus so I
am responding with a new note.
Anyway, here's my reply to your question.
You didn't mention what operating system you are using or what version of
MySQL you have. I am running MySQL 4.0.15 on Linux Mandrake 8.1.
This is a bash script that I wrote for myself to do automated backups. It
doesn't include the FTP stuff that you wanted but I'll leave that up to you
and/or the others on this mailing list ;-)
Unfortunately, the script wraps when I cut and paste it so I've put it in
a file attachment for you (and anyone else who wants it).
I commented the code fairly heavily when I wrote it so it should be
more-or-less self-explanatory if you know bash. However, feel free to post
followup questions if you need anything explained to you. You'll need to replace
the question marks in the USERID and PASSWORD variables with your own values;
likewise, you will want to modify the BACKUP_PATH variable to identify where you
want your backups written and set NUMBER_OF_DAILY_BACKUPS_TO_KEEP to the number
you want. You should probably leave BACKUP_TIMESTAMP alone.
The echo statements are just so that I have a nice report that tells me
exactly what is happening; you can omit them if you don't want the report.
The 'for' statement simply gets a list of all of the database names on my
copy of MySQL; the 'do' loop that follows makes a mysqldump backup of the
database, then backups older than 7 days are displayed and then deleted.
I've been using this without problems for a year or so. Rhino
--- rhino1 AT sympatico DOT ca "There are two ways of constructing a software design. One way is to make it so simple that there are obviously no deficiencies. And the other way is to make it so complicated that there are no obvious deficiencies." - C.A.R. Hoare |
<<tech.gif>>
-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]