Skip to content
nanch edited this page Mar 30, 2013 · 15 revisions

Follow these simple steps to backing up your linux system!

1. Get your tarbackup.com account

Go to https://tarbackup.com and create an account for free.

2. Backup your system

mkdir /backups
tar -cvpzf /backups/fullbackup.tar.gz --directory=/ --exclude=proc --exclude=sys --exclude=dev/pts --exclude=backups .

3. Encrypt the tar file

first you have to create your secret key so that nobody can ever see your backed up files. This ensures security on your end and my end. You have to keep this key in a safe place on a usb drive, other computer, or in your email. If you have a crash and you lose the key, you can't restore your files!

create your secret key

echo mysupersecretkey > /backups/key

or

# dd if=/dev/urandom bs=1024 count=1 | base64 > /backups/key

encrypt your backup with openssl (the command to decrypt is in the "Restoring your data" section)

openssl enc -aes-256-cbc -salt -in fullbackup.tar.gz -out fullbackup.tar.gz.enc -pass file:/backups/key

4. Upload your backup

cd /backups
sftp [email protected]:/storage/
> put fullbackup.tar.gz.enc
> quit

Restoring Your Data

1. Download your data from tarbackup via sftp

mkdir /restores
cd /restores
sftp [email protected]
> get fullbackup.tar.gz.enc
> quit

2. Decrypt the file

openssl enc -d -aes-256-cbc -in fullbackup.tar.gz.enc -out fullbackup.tar.gz -pass file:/path/to/secret/password.txt

3. Extract your data

tar -xvzf fullbackup.tar.gz -C /

Learn More

Where the data is stored

Build your own

History of tarbackup

2013-09-12 http://www.reddit.com/r/linux/comments/zt1md/hey_linux_im_making_a_free_linux_backup_service/