Changeset 344 for tools


Ignore:
Timestamp:
Sep 8, 2011, 5:52:28 PM (13 years ago)
Author:
Rick van der Zwet
Message:

Avoid potential directory disaster.

Location:
tools
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • tools/config-snapshot.sh

    r343 r344  
    1616
    1717# Check for last backup file
    18 mkdir -p $BACKUPROOT
     18mkdir -p $BACKUPROOT || exit 1
    1919LAST=`ls -t1 $BACKUPROOT/*.tar | head -1`
    2020
  • tools/mysql-snapshot.sh

    r343 r344  
    1414
    1515BACKUP_TODAY=`date "+$BACKUP_ROOT/%Y/%m/%d/"`
    16 mkdir -p $BACKUP_TODAY
     16mkdir -p $BACKUP_TODAY || exit 1
    1717# Dump and compress
    1818for DATABASE in $DATABASES; do
  • tools/snapshot-sync.sh

    r343 r344  
    3131  TARGET=$SNAPSHOTROOT/$DIR
    3232  SOURCE=/usr/backup/$HOSTID/$DIR
    33   mkdir -p $TARGET
     33  mkdir -p $TARGET || exit 1
    3434
    3535  # now the actual transfer
  • tools/vmail-snapshot.sh

    r343 r344  
    77
    88TARGET=/usr/backup/`host -s`/vmailbackup/virtual.tar.gz
    9 mkdir -p $TARGET
     9mkdir -p $TARGET || exit 1
    1010tar -C /var/mail -czf $TARGET virtual
    1111
Note: See TracChangeset for help on using the changeset viewer.