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 looking to backup a home directory of mine to a cloud service such as Dropbox or Ubuntu One. It is my account on my university's servers. We recently had a file server failure but luckily they kept backups. I figured I shouldn't rely on this alone

Are there any utilities or services I can use versus a tarball that I upload directly?

I only have ssh access to my account and would like to sync it in this fashion.

share|improve this question
    
I suppose I want to know how I can proceed with this? Are there any utilities rather than tarring my directory and uploading that. I can update my question. –  squiguy Oct 18 '12 at 6:39
    
does your university have rsync, git, bxr, or hg installed that you can use for version-control based backup? –  Ben West Oct 18 '12 at 7:12
    
@BenWest Yes, I have looked at rsync. I am not really looking to use version control, just a pure backup of /home to a cloud storage provider. I thought I may as well use up all that free space :). –  squiguy Oct 18 '12 at 7:17
add comment

2 Answers 2

up vote 0 down vote accepted

I suggest you look into sparkleshare. It provides many of the features of dropbox or ubuntu one (and could integrate with them) and may work on generic UNIX. if it doesn't you might consider using vanilla git, instead.

Barring that, setting up a cron job that ssh's to the server on a schedule and downloads the files would be a viable option.

the script run by the cron job could be as simple as

ssh user@remote_host "tar -cf - ~" | bzip2 -zc | cat > ~/dropbox/$(date | sed 's/\ /\-/ig')-rhost_backup.tar

or in laymans terms: "using ssh, on remote system call: 'create an archive of %HOME_DIR% and dump it into the console' zip that with bzip2, and put that in a timestamped file in my dropbox (assuming your dropbox is at ~/dropbox).

Obviously, this makes some asumptions about your client system, etc. There are probably ways you could do this on windows, Mac should be very similar. There are also options for tar that will allow you to only store new versions of the files, etc.

share|improve this answer
    
Please see the OP's edit. They specifically would like to know how to go about syncing their remote home direcotry. –  slhck Oct 18 '12 at 7:02
    
I found an alternative method similar to yours so thank you for the idea. –  squiguy Oct 19 '12 at 21:09
    
Please post your method as an answer? I'll happily give up the reputation –  Ben West Oct 21 '12 at 0:59
add comment

Dropbox does offer a linux client here. You should be able to easily set up and run it since you have shell access.

However, as already suggested, simply syncing one directory to another is not as safe as you might think. If some of your files are accidentally deleted and then synchronisation runs your backup directory will also get emptied (I've never used Dropbox but I assume that this is how it works - if not, go ahead and use it)

Make sure you frequently manually verify that your backups are functioning.

share|improve this answer
    
I have the client on my own laptop actually. The thing is, I would like to do it remotely because I can not install software on my school's computers. So if that were not the case then I would have proceeded with your idea. –  squiguy Oct 18 '12 at 16:03
    
You shouldn't need root access to use it (according to the instructions in the link at least), or are you not allowed to run executables from your home directory? –  zmode Oct 18 '12 at 17:57
    
Unfortunately I don't have access to install a client or else I may have already done so. –  squiguy Oct 18 '12 at 19:41
    
All you have to do is extract that compressed file and execute the script inside it. Are you sure it needs more permissions than that? If you're sure you can't get it to work you'll have to use another method I'm afraid. –  zmode Oct 18 '12 at 21:09
add comment

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.