Phil, the script you want sounds like it will be very customized to your host. I'd suggest starting by doing the commands you want by hand, from the command line. Once you see success here, save (cut & paste) the commands you used to a file. Better, save each command as you run it (my choice!) so you don't get to the end and wonder what that second command was... Also, have a look the "mysqldump" command. This may meet your needs without requiring a MySQL server shutdown. I would be very hesitant using example scripts here. Perhaps only use somebody else's scripts to get ideas from, but use these only where you really know what each command in the script is doing. The real kicker here, get another computer, install from scratch, restore from your backup, see if it really works. If you don't do this, some day in the future you may be very sorry. Prove the backup really works! (I speak from very painful real-world experience!) - tom e. ------------- On Mon, 23 Sep 2002, Phil Mattison wrote: > Hello Fellow PLUGers, > I have a Linux server running Apache/PHP/MySQL, and want to setup > automatic daily backups for the database. I'm planning to install a second > hard drive to receive the backup data, and will modify the web site to > exclude access while backups occur. I'm wondering if anyone has written > scripts to do similar tasks and would be willing to share some examples. I'm > thinking the script needs to do something like the following: > Stop MySQL > Copy the database files to the backup drive > Restart MySQL > It also would be nice to get a daily report of disk usage and the size of > the backups. If anyone has any tips or examples they would be much > appreciated. > Thanks, > -- > Phil Mattison > Ohmikron Corp. > 480-722-9595 > 602-820-9452 Mobile > > -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- > PLUG-discuss mailing list - PLUG-discuss@lists.plug.phoenix.az.us > To subscribe, unsubscribe, or to change you mail settings: > http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss >