So a couple weeks ago I posted on the progress I had made with backups, and have made significant progress since then. I wanted to update my readers and document my backup system.
Here are the components:
1) Various Ubuntu 6.06 Vmware guests running a cron job to backup data via rsync to a Ubuntu 6.06 file server VM sharing out a backup target via SAMBA. All of the virtual machines are on one system. These backups are for accidental deletion or recovery from a system intrusion. Obviously if the hard drive fails it doesn't do me any good having the data on the same machine. :)
This has been in production for about a week and is running quite nicely. Still haven't figured out the permissions error I get, but am living with it for now. The script is fairly simple:
It allows me to easily add systems and I can use the same script on every server. This is a 3rd or 4th generation backup script. :)
2) A cron job that runs nightly on the file server and does an rsync via SSH backup of the following:
a) My various web properties hosted on a VPSLAND Xen slice.
b) My e-mail and homepage at thewybles.com
3) A cron job that runs nightly on the file server and does an rsynv via SSH to my rsync.net account. I currently have 3gigs of space at that account and can easily add more. I highly recommend checking them out. A tad slow but thats to be expected I suppose. :)
So I am in pretty good shape on the Linux side of the house. My data exists live and in 2 backup locations. One of which is under my direct physical control.
Need to do some work on the Windows systems still...
Here are the components:
1) Various Ubuntu 6.06 Vmware guests running a cron job to backup data via rsync to a Ubuntu 6.06 file server VM sharing out a backup target via SAMBA. All of the virtual machines are on one system. These backups are for accidental deletion or recovery from a system intrusion. Obviously if the hard drive fails it doesn't do me any good having the data on the same machine. :)
This has been in production for about a week and is running quite nicely. Still haven't figured out the permissions error I get, but am living with it for now. The script is fairly simple:
#!/bin/sh
excludeFile="/usr/local/bin/backup_excludes"
#includeFile="/usr/local/bin/backup_includes"
logFile="/usr/local/bin/backup.log"
bkupDir="/mnt/backup/`date +%A`"
ping -c 2 fileServer
backupDestAvail=$?
echo "To: charles@thewybles.com" > ${logFile}
echo "From: vmware-backup@thewybles.com" >> ${logFile}
echo "Subject: Backup Ran `date`" >> ${logFile}
echo "" >> ${logFile}
echo "Starting Backup script `date`" >> ${logFile}
echo "" >> ${logFile}
if [ ${backupDestAvail} -ne 0 ]
then
echo "Aborting Backup script due to backup destination being unavailable `date`" >> ${logFile}
else
#
# mount the drive
#
mount -t cifs -o username=vmbackups,password=**** //fileServer/`hostname` /mnt/backup >> ${logFile} 2>&1
#
# make sure the directory is there
#
if [ ! -d ${bkupDir} ]
then
echo "Creating backup directory ${bkupDir}" >> ${logFile}
mkdir ${bkupDir} >> ${logFile}
else
echo "Output Directory Already Exists" >> ${logFile}
fi
#
# now run rsync on the system.
#
rsync -vaPx --numeric-ids --delete --exclude-from=${excludeFile} / ${bkupDir} >> ${logFile}
echo "System Backup Complete `date`" >> ${logFile}
umount /mnt/backup
fi
cat ${logFile} | /usr/sbin/sendmail -t -i
It allows me to easily add systems and I can use the same script on every server. This is a 3rd or 4th generation backup script. :)
2) A cron job that runs nightly on the file server and does an rsync via SSH backup of the following:
a) My various web properties hosted on a VPSLAND Xen slice.
b) My e-mail and homepage at thewybles.com
3) A cron job that runs nightly on the file server and does an rsynv via SSH to my rsync.net account. I currently have 3gigs of space at that account and can easily add more. I highly recommend checking them out. A tad slow but thats to be expected I suppose. :)
So I am in pretty good shape on the Linux side of the house. My data exists live and in 2 backup locations. One of which is under my direct physical control.
Need to do some work on the Windows systems still...
