Belt and Braces

Dear Reader,

Well I’m now putting in place measures to stop all my work disappearing again! (To be fair it was only one days work, but it annoyed me enough to want to do something about it)

So now I have flyback working on two computers, the one in the office and the one at home and also in the office I have rdiff-backup working to an external hard drive.

This is done by a number of lines in crontab such as:

0 1 * * 0,3 /usr/bin/rdiff-backup /media/sdb1/username/data/archive /mnt/usbback/archive
0 2 * * 0,3 /usr/bin/rdiff-backup --remove-older-than 9M /mnt/usbback/archive

Two important things:Note 1: the full path of rdiff-backup is specified as cron doesn’t use environment variables.

Note 2: Using an external hard drive with FAT32 doesn’t work with rdiff-backup. Reformating in Ubuntu is tricky using gparted as the darn thing automounts everytime you try to reformat. I found a hint on a forum to use the openbox window manager to run gparted which solves that problem. Once you have reformated as ext3 you then have to make sure you have permission to write to the drive, this I did by altering the /etc/fstab file like this:

/dev/sdc1 /mnt/usbback ext3 defaults 0 2

and then ensuring the /mnt/usbback directory was owned by the user (well me) that I wanted to run the backups on.

This eventually appears to have worked….


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s