Need to clear old directory before backup begins personal-scripts tip
authorSam Hart <criswellious@gmail.com>
Fri May 09 11:00:30 2008 -0400 (2 months ago)
branchpersonal-scripts
changeset 507dfbe97f63a7
parent 493c1e25e76f4d
Need to clear old directory before backup begins
trunk/qnd-mysql-backup.sh
       1 --- a/trunk/qnd-mysql-backup.sh	Fri May 09 10:57:46 2008 -0400
       2 +++ b/trunk/qnd-mysql-backup.sh	Fri May 09 11:00:30 2008 -0400
       3 @@ -25,6 +25,9 @@
       4  for a in $ALL_DBS
       5  do
       6      trace "Working database: $a"
       7 +    trace "Clearing old backup"
       8 +    rm -vfr $DEST_DIR/$a >> $LOG_FILE 2>&1
       9 +    trace "Running backup"
      10      mysqlhotcopy $a $DEST_DIR >> $LOG_FILE 2>&1
      11  done
      12