Tuesday, May 22, 2012

Syncing any existing folder to Dropbox/Google Drive/Sky Drive

I am a big fan of cloud storage. I've used Dropbox for documents and Sugasync for work for quite a while. They are both great but with the recent addition to the family I decided it was about time to start backing up my photos in the cloud as well. I've currently got somewhere between 25 and 30 Gb of photos on my computers and this exceeds the free storage limit for Dropbox, even if I do maximise my referrals (click here to sign up and earn me more space please :) ). Thankfully I managed to dredge up my (poorly named) Hotmail address from the dark ages (I think I signed up in '97!) and score a 25 Gb Skydrive account I am not sure if the offer still exists but you get 7 Gb just for signing up). Unfortunately this still wasn't quite enough space for all my photos so I had to sign up for Google Drive as well to get enough storage overall.

The downside of these tools (except I might add SugaSync) is that they create a folder on the drive and everything in there is synchronised into the cloud. This is great as it is quite simple, but it is a pain if you want to maintain an existing folder structure, such as the storage hierarchy for all my photos. On *nix you'd simply create a symlink or two in the newly created folder pointing to the existing folders you want to mirror and be done with it. Unfortunately it is not that simple in Windows world, NTFS (the file system used by newer versions of Windows) does support the idea of Symbolic links through something they call junctions, but it is not available by default. Fortunately, there a a few programs out there that can be used. After a bit of poking around I found a few different programs and ways to go about it. Starting from this blog post which has a good description of the nitty gritty, I also found this question on SuperUser to be helpful. In the end I installed Link Shell Extension which adds handy options in the contextual menu and works in both XP (where I tested it) and Windows 7 environments.

Once it is installed you need to pick your source folder right click on it and select "Pick Link Source" then you navigate to your SkyDrive/Google Drive/Dropbox folder and select "Drop As.." then "Hardlink clone" if you are dropping a single file then "Junction" should work. "Hardlink Clone" ensures that all the underlying folders and files are linked as well.

Now I am slowly uploading the files to their various destinations and maintaining my file structure at the same time!