Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

What options do I have for backing up the content from a Rackspace Cloud Sites including files and databases? I know they have cron jobs, but I am not sure what options I have when it comes to that.

Here are some of the things the cron jobs they have support.

share|improve this question
add comment

7 Answers 7

I use two scripts to back up my VPS (hosted on Linode, but the same should work on Rackspace).

First, for mysql backup, I use the automysqlbackup script. It takes care of dumping your databases, compressing them, and maintaining several daily/weekly/monthly copies of the backup files. It can also email you the compressed .sql dumps as well.

For general filesystem backup, I use duplicity - this can use a number of different storage backends (ftp, scp, nfs, etc), but I choose to use the Amazon S3 backend. Duplicity will do either full or incremental backups depending on your need. It will also handle compression of your backup files as well as encryption if you so desire.

share|improve this answer
1  
With rackspace I do not have shell access. –  Daniel A. White Dec 17 '09 at 16:33
add comment

Rackspace doesn't allow SSH to their Cloud Sites so I don't think Duplicity will work unless you can convince them to install it.

We were looking for a solution as well, but ended up building a backup system which archives files and SQL dumps and transfers them to Rackspace Cloud Files, named and dated. The system handles cleaning up old backups (we keep a variety of daily/weekly/monthly backups) and works as a module on a dedicated Drupal install. The admin gives feedback on the status of each backup and populates a Google spreadsheet to give an overview. It can also work with any site outside of Rackspace, since it's using a PHP client to do all the work (upload one PHP script to the sites you want to back up, set it up on the admin UI, and the master site will take care of all the scheduling/authentication/etc...) We're using it internally but may release it as a module if there is any interest for it, so let me know.

share|improve this answer
1  
duplicity supports the python-cloudfiles library which allows backup to rackspace cloud using duplicity, also to any openstack target - take-your-vitamins.blogspot.com/2012/02/… –  Tom H Feb 20 '12 at 4:09
add comment

I tried http://www.zipitbackup.com/ . Its backup utility from rackspace. It works well.

Documentation says How it works:

->Runs on a per-site basis. The Zipit Backup Utility must be installed for each site you want to back up.

->The Zipit Backup Utility backs up all Cloud Sites files and databases to your Cloud Files account.

->Lists all available backups. Available backups can be managed via the Cloud Control Panel.

share|improve this answer
add comment

The only way I know of is to create a cron job to backup your data and databases and have it ftp or whatever method you want to use for transmission of data. Here is a sample script.

#!/bin/sh
# System + MySQL backup script
# Full backup day - Sun (rest of the day do incremental backup)
# Copyright (c) 2005-2006 nixCraft 
# This script is licensed under GNU GPL version 2.0 or above
# Automatically generated by http://bash.cyberciti.biz/backup/wizard-ftp-script.php
# ---------------------------------------------------------------------
### System Setup ###
DIRS="/home /etc /var/www"
BACKUP=/tmp/backup.$$
NOW=$(date +"%d-%m-%Y")
INCFILE="/root/tar-inc-backup.dat"
DAY=$(date +"%a")
FULLBACKUP="Sun"
### MySQL Setup ###
MUSER="admin"
MPASS="mysqladminpassword"
MHOST="localhost"
MYSQL="$(which mysql)"
MYSQLDUMP="$(which mysqldump)"
GZIP="$(which gzip)"
### FTP server Setup ###
FTPD="/home/vivek/incremental"
FTPU="vivek"
FTPP="ftppassword"
FTPS="208.111.11.2"
NCFTP="$(which ncftpput)"
### Other stuff ###
EMAILID="admin@theos.in"
### Start Backup for file system ###
[ ! -d $BACKUP ] && mkdir -p $BACKUP || :
### See if we want to make a full backup ###
if [ "$DAY" == "$FULLBACKUP" ]; then
FTPD="/home/vivek/full"
FILE="fs-full-$NOW.tar.gz"
tar -zcvf $BACKUP/$FILE $DIRS
else
i=$(date +"%Hh%Mm%Ss")
FILE="fs-i-$NOW-$i.tar.gz"
tar -g $INCFILE -zcvf $BACKUP/$FILE $DIRS
fi
### Start MySQL Backup ###
# Get all databases name
DBS="$($MYSQL -u $MUSER -h $MHOST -p$MPASS -Bse 'show databases')"
for db in $DBS
do
FILE=$BACKUP/mysql-$db.$NOW-$(date +"%T").gz
$MYSQLDUMP -u $MUSER -h $MHOST -p$MPASS $db | $GZIP -9 > $FILE
done
### Dump backup using FTP ###
#Start FTP backup using ncftp
ncftp -u"$FTPU" -p"$FTPP" $FTPS<
mkdir $FTPD
mkdir $FTPD/$NOW
cd $FTPD/$NOW
lcd $BACKUP
mput *
quit
EOF
### Find out if ftp backup failed or not ###
if [ "$?" == "0" ]; then
rm -f $BACKUP/*
else
T=/tmp/backup.fail
echo "Date: $(date)">$T
echo "Hostname: $(hostname)" >>$T
echo "Backup failed" >>$T
mail -s "BACKUP FAILED" "$EMAILID" <$T
rm -f $T
fi
share|improve this answer
add comment

A Cron job running a script seems like a more "solid" solution to me. I am still in the process of getting away from my dependency on GUI's. D:

That being said, I use Cobian Backup to automatically backup all site files @ cloudsites via FTP on a nightly basis. It's a pretty good fire and forget solution that requires no scripting knowledge or Cron jobs, just make sure you test restore periodically.

More details here: http://www.iainlbc.com/2010/04/how-to-backup-rackspace-cloudsites-automatically-incrementally-using-free-software/

MySQL Administrator(EOL) handles the automated backups of our amazon RDS

share|improve this answer
add comment

very simple script for backup in rackscpace cloud files with duplicity

http://github.com/contenidosonline/cloud-files-backup

share|improve this answer
add comment

The Zipit Backup Utility is really the best option for now. I am actually the developer of it and have worked hard to make it as robust as possible. I am constantly working to make it better and have just released a major update to it.

You can check it out at http://zipitbackup.com

Regards, Jereme Hancock Cloud Sites Support Automation Admin

share|improve this answer
add comment

protected by MadHatter Sep 4 '13 at 6:05

Thank you for your interest in this question. Because it has attracted low-quality answers, posting an answer now requires 10 reputation on this site.

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.