2 ################################################################################
4 # File: $RCSfile: backup,v $
5 # Revision: $Revision: 1.7 $
6 # Description: This script backs up the system in a consistent way
7 # Author: Andrew@DeFaria.com
8 # Created: Tue Jul 27 15:00:11 PDT 2004
9 # Modified: $Date: 2011/05/26 06:17:20 $
12 # (c) Copyright 2000-2005, ClearSCM, Inc., all rights reserved.
14 ################################################################################
20 if [ -f /etc/dump.excludes ]; then
21 excludes="-E /etc/dump.excludes"
26 if [ $(id -u) -ne 0 ]; then
27 echo "You must be root to backup"
34 echo "Usage: backup <full | incremental>"
43 if [ "$type" = "full" ]; then
44 rm -f $dumppath/$host.$type.backup
45 rm -f $dumppath/$host.$type.backup.log
46 rm -f $dumppath/$host.$type.list
48 elif [ "$type" = "incremental" ]; then
54 log=$dumppath/$host.$type.backup.log
57 -A $dumppath/$host.$type.list\
58 -f $dumppath/$host.$type.backup\
61 -u $files2backup > $log 2>&1