SEO Tips - SEO Blog - Internet Marketing - Search Engine Optimization

Backing up MySQL databases

  1. #1 mrtran
    November 15th, 2008 at 1:14 pm

    You also need to create the tar directory under your $BACKUPPATH directory, for example /var/www/backup/tar

    I keep my old backups, so I remove the rm command, and add the date to each tar file by changing the tar and gzip commands to be:

    tar -cvf $BACKUPPATH/tar/${bbdd[$index]}.`date +%F`.tar ${bbdd[$index]}/* > /dev/null
    gzip $BACKUPPATH/tar/${bbdd[$index]}.`date +%F`.tar > /dev/null

    It’s also important to note that the mysqlhotcopy line has two double dashes in it, before password and allowold. WordPress is converting those into an em dash, which renders badly. Same problem with the quotes in the bbdd and let commands.

    Post ReplyPost Reply
  2. #2 Forex Researcher
    February 23rd, 2010 at 5:50 am

    Enjoyed this, good read, thanks

    Post ReplyPost Reply
Leave a Comment