You are not logged in.

#1 2007-05-31 00:20:45

Jedi Stannis
Member
Registered: 2004-09-10
Posts: 65

Good backup solution

My hard drive recently died, and of course I didn't have a good backup solution in place.  I'm about to rebuild my system and was looking for some recommendations.  I think I'm gonna put two large internal hard drives in and use one for back up.  Possibly use a cron job to call some sync tool on directories I want backed up?  Any other ideas, suggestions?  Thanks

Offline

#2 2007-05-31 00:55:24

Alphalutra1
Member
Registered: 2006-09-16
Posts: 59

Re: Good backup solution

Two internal drives will work, but the one problem is that you are putting all of your data in the same place, so if some sort of electrical surge came that fried the entire computer, or another weird accident, then both your backups go at the same time.

So, the best thing may either be to use an external drive and unplug it when you aren't using it, or have another computer on the LAN or somewhere else with a hard-drive then do backups over the network.

The best tools are dump(8) and restore(8) from my experience with using them in the BSD world.  I would assume they would work equally as well in linux.  The man files will tell you pretty much all you need to know, then just add that to cron to run weekly or whatever, with incremental updates every day and full ones each week.

Cheers,

Alphalutra1

Offline

#3 2007-05-31 01:00:37

ataraxia
Member
From: Pittsburgh
Registered: 2007-05-06
Posts: 1,553

Re: Good backup solution

I use "dump" to backup over the network to another machine. (That machine, running Mac OS X, backs up to an external disk.) When my Arch box croaks, I use "restore" to put it back. Since the Arch install CD doesn't have restore, I use SystemRescueCD.

This will work for ext2, ext3, and xfs (with xfsdump/xfsrestore), but not for other filesystems, since they don't have dump/restore utilities. I do the same thing for other OSs. I've tested it many times and it's always a winner. Very simple, and no scripting to cause bugs.

If you don't have a second machine, I'd suggest doing the same thing, but to a second disk. I suggest an external disk, though, since you can power it off and unplug it when you're not using it - nice protection from software screwups and electrical dangers. Buy an enclosure for $30 and put an ordinary disk in it - much cheaper than a pre-built external.

EDIT: I see someone else beat me to the punch, but said the same thing! That should just make it more convincing... lol

Last edited by ataraxia (2007-05-31 01:01:39)

Offline

#4 2007-05-31 07:30:50

chicha
Member
From: France
Registered: 2007-04-20
Posts: 271

Re: Good backup solution

I use rdiff-backup (http://www.nongnu.org/rdiff-backup/) which is very simple to use and very conveniant :
I have 2 seperate hardisks, and I daily backup my /home, and /etc directory using a  cron task. It does not take long to execute even if I have several Go to backup. You can purge old backup and restore a backup at a particular date very easily.

I recommand it if you are a basic desktop user. If you are in a professional environnement maybe the other solutions detailed above are better ...

Offline

#5 2007-05-31 08:28:50

onearm
Member
From: Anywhere but here
Registered: 2006-07-06
Posts: 359
Website

Re: Good backup solution

I do the same as chicha, plus once in a month I backup everything to an external usb hard drive just in case the internal ones die.


To get something done, a committee should consist of no more than three persons, two of them absent.
--
My Github

Offline

#6 2007-05-31 11:51:05

hungsonbk
Member
Registered: 2007-05-26
Posts: 105
Website

Re: Good backup solution

yikes:o What about Rsync. this is a traditional way to backup, and it can be tuneled inside SSH as well. I am using it to backup my webserver and it is GREAT:D:D

Offline

#7 2007-05-31 12:05:46

z3ppelin
Member
Registered: 2006-07-10
Posts: 171

Re: Good backup solution

I'm also using rsync, it's very good for simple tasks I need - backuping /etc/ and ~/.

Offline

#8 2007-05-31 13:23:12

Mikko777
Member
From: Suomi, Finland
Registered: 2006-10-30
Posts: 837

Re: Good backup solution

Thanks for rdiff-backup smile

Follow up question:

Now I backup both desktop and laptop to a different partition usin rdiff-backup So how do i compare the differences between the two backup directories? Both inside files and just the file directory difference? ie .pacnew vs original file?

Offline

#9 2007-05-31 13:33:12

chicha
Member
From: France
Registered: 2007-04-20
Posts: 271

Re: Good backup solution

I do not understand what you want to compare ... !?
Do you have 2 different computers, and a backup for each of your computer ?
rdiff-backup is usefull to compare a directory and its backups at a given time. But it is not made to compare two different directories ... there are other tools for that.

Can you please give some more details on what you would like to do ?

Offline

#10 2007-05-31 15:24:16

Mikko777
Member
From: Suomi, Finland
Registered: 2006-10-30
Posts: 837

Re: Good backup solution

chicha wrote:

I do not understand what you want to compare ... !?
Do you have 2 different computers, and a backup for each of your computer ?
rdiff-backup is usefull to compare a directory and its backups at a given time. But it is not made to compare two different directories ... there are other tools for that.

Can you please give some more details on what you would like to do ?

Yes being linux newbie i'm trying to find a program / way to compare two different folders and another app / way to compare two separate file's contents and finding out the differences smile

Small easy example: Doing pacman -Q > packages.txt ono both computers then having 2 files and running some program to check what apps are installed on one computer but not on another.

Then the same with files, does the backups contain same themes, bookmarks etcetera...

Last edited by Mikko777 (2007-05-31 15:27:53)

Offline

#11 2007-05-31 16:07:26

ataraxia
Member
From: Pittsburgh
Registered: 2007-05-06
Posts: 1,553

Re: Good backup solution

Use "diff" for this.

diff -u file1 file2 (for just a pair of files)

diff -ru dir1 dir2 (for two whole directories, this can be slow since it reads all the files in both completely)

Offline

#12 2007-06-01 01:33:03

chilebiker
Member
From: Zurich, Switzerland
Registered: 2006-07-18
Posts: 161

Re: Good backup solution

I use rsync to backup my system and data on a external USB HD (using a daily cron job). It's very simple and works without problem.

# Backup Arch to USB-HD (sdb2)
rsync -a --delete --delete-excluded --numeric-ids --exclude /dev --exclude /mnt --exclude /proc --exclude /sys --exclude /tmp --exclude /var/tmp --exclude /**/.mozilla/**/Cache / /mnt/sdb2/

# Backup Data to USB-HD (sdb1)
rsync -a --delete --delete-excluded --numeric-ids /mnt/data/ /mnt/sdb1/

Don't panic!

Offline

Board footer

Powered by FluxBB