Back up your data, please – and keep multiple backups
I learned a very important lesson about electronic data today.
I’m crazy about my backups. I typically back up my data about once a week using a command line script that I wrote to circumvent the use of Time Machine. At any time, two separate physical drives and my laptop’s internal hard drive contain redundant copies of all of my important data. I keep the last backup on the drives until it’s replaced by the current one. As it turns out, this last part is not a very good idea.
I recently started using Dropbox to move files easily between my three different filesystems (Mac on Pro and MacBook, and Linux on the MacBook partition). It’s quite a convenient service, but it has one interesting behavior that I learned to watch out for. Typically, when you click and drag a file or folder into a new location, Finder’s default behavior is to copy the file to its new location, keeping the original intact. However, for whatever reason, the Dropbox folder behaves differently, relocating dragged folders and files instead of copying them. You have to manually copy from the local location to the Dropbox if you want two copies.
I’ve been working on a computer game for a little while now, and I have 2000+ lines of Java that drive it, combined with font and image data that I created myself. I typically work on the code/images in multiple locations, which is actually one of the main reasons I started using Dropbox. I checked on my local drive for the first time in a while to see what state my code was in, and, as you may have been able to guess, it wasn’t there. Not anywhere. My backup drives didn’t have it either. Apparently I’d done the last backup after inadvertently deleting my code by dragging it into the Dropbox – so I had no hard copies left. At this point, about an hour ago, I had resigned myself to the dozens-of-hours project being over.
Enter the soon-defunct cloud storage service drop.io. I used it before Dropbox, and made the switch mainly because of the impending end of their company after a talent acquisition by Facebook. Having used drop.io to move around the source code for my game a few times, I figured that was my last hope in finding it again. My account password had been deactivated, though, so my attempts to login were in vain. It also wasn’t helping that the drop.io homepage is all but shut down – they don’t allow any new drops to be created, for one thing. After a bit of digging through my mail trash, though, I managed to find the confirmation email I got from drop.io when I registered the drop – complete with the original drop name and password. Those worked, and luckily the compressed source was still there.
Obviously, a lot of things could have gone wrong. Like my computer automatically emptying my mail trash folder, or drop.io going offline sooner that expected, or me having previously removed the code from the drop. Needless to say, I’m very relieved that I managed to get the code back. Thank goodness for cloud storage.
So what did I learn from this? Well, mainly I learned to be careful when I copy stuff to the Dropbox. But I also have already modified my backup script to include the folder that contains code for any project in six redundant locations, just in case one (or five) get corrupted somehow. Also, I’m going to start saving two backups at a time instead of only the most recent one. That way, it’ll be possible to look at a greater span of time and hopefully recover some files that way. That certainly would have helped in this instance.
Check out this “wall PC” that somebody of the internet built. I’m jealous.