Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I was trying to back up my $HOME at Ubuntu by copying the home directory to a SSH server using scp.

But I found that the copy operation soon fell into some endless cycle, repeatedly copying some files. I found some of these files were in my dropbox directory under $HOME, and I was not able to check if there were files in other directories. During that backup, I only had local network connection and not internet connection to connect to dropbox server.

I was wondering if someone happens to know what is happening? Copying which directories under $HOME may cause endless cyclic operations? What non-user created directories are worth backup?

Thanks!

share|improve this question
    
"worth of backup" .. that depends on what is worth to YOU :) –  akira Feb 12 '11 at 19:24
    
@akira: ~/.porn/, of course. –  grawity Feb 12 '11 at 20:21

2 Answers 2

Use rsync. It uses SSH as transport like scp, but is more suited to backups because of the abilities to preserve file metadata and to only copy changed files.

rsync -avAXSP ~ backupserver:/backups/Tim/

(Here -A and -X mean "preserve ACLs and xattrs". If these features are disabled on your backup server, remove these two options.)

share|improve this answer

scp -r ${HOME} user@server:/location/to/backup/to.

Or from the server:

scp -r user@computer:~/ /location/to/backup/to.

As grawity stated you are better off using rsync. Or a much more powerful solution is rsnapshot. Both will work over ssh so you don't need to install anything besides the client (rsycn or rsnapshot) onto the machine you want to run the backups from.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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