tech tuesday: hard drive recovery

If someone wanted to ransom every picture you ever took and all your music and your thesis to you, and you didn’t have a good enough relationship wtih Chuck Norris to ask him to hunt them down and roundhouse kick them into infinity meaning you had to pony up, how much money would you pay?

I mean, we’re talking about things that pretty much only have sentimental value. You know, the stuff that you care most about?

$100? $1000? $10K?

I bet for most people, a mere $100 would seem like an extremely cheap price to pay to get your photos back.

This is where I point out that large external hard drives, likely large enough to hold the contents of your entire laptop, are between $80 and $120. So from now on, if your data only lives on one hard drive, it may as well be baLEETed already. Please don’t come crying to me after reading this post. And don’t try to pretend you haven’t read it either; my secret intarwombat spy marsupials send me extremely detailed TPS reports on my audience and they know everything, even what you do under the sheets when you think no one is looking.

Alright, so since I haven’t talked about this topic yet, you get a mulligan. As my mom would say, “ain’t you happy?!” Let’s say your main drive died and you don’t have backups. This scenario was riddled me by the lovely Erin as a comment on last week’s entry.

First, as Miracle Max so sagely pointed out, there’s a difference between all dead and mostly dead. If you hear clicking or grinding or otherwise alarmingly loud sounds screeching out of your drive, it’s all dead. At this point, your option is to listen to Chicago’s Greatest Hits, cry for a while, and then pay a lot of money to a real miracle worker who will charge at least $1000 if not more to get your data back. And they will not coat the bill in chocolate to make it go down easier.

But if the drive is only mostly dead, then you can get a lousy miracle from the guy the king’s stinking son fired.

This lousy miracle consists of two parts.

First, you need a way to physically connect your old drive to a current working computer. If your laptop drive died, and it probably did since laptop drives are made out of expired cotton candy, a product like this docking station will probably work. Hopefully you can just borrow one (sorry, I don’t own one currently), but if not, just buy it. $32 is peanuts compared to what you’re going to pay to the real miracle worker if the lousy miracle doesn’t work, so you may as well just grin and bear it.

Oh, I forgot to mention that you’ll need another external hard drive. This drive needs to be at least as big as your old, mostly dead drive, and preferably larger. We use this drive as the place to store your [hopefully] recovered files. Also, when we’re done attempting to recover files, it will serve as your brand new backup drive. Ain’t you happy?!

The second part of the solution is to download this jawesome, free program called TestDisk. It’s free as in beer, and Free as in speech, and you can’t beat that with a spaghetti noodle.

Run the program and be prepared to wait. A lot. When my 2TB drive got hosed, it took around 72 hours to complete. The source disk is your mostly dead disk and the target disk is your new external hard drive.

After your long wait, hopefully TestDisk did the right thing and found your files. Again, on my 2TB drive, it did quite well finding JPGs and RAW photos, my MP3s, and assorted other documents.

One annoyance with TestDisk is that it creates zillions of directories with grillions of files in them, none with descriptive names. This is a huge pain to sort through. I wrote a small python script that can walk through those directories and at least group them together by extension, so all your JPGs will be in the same place.

You can grab it here:

The script is quick n’ dirty, so if anyone out there actually does need to run it, drop me a line and I can try and clean it up a little bit for you.

And that’s it — a lousy miracle because the sound your hard drive was making was actually “to blathe” which as we all know, means “to bluff”. If TestDisk didn’t work for you, your only real option is to send it to a real miracle worker, who will definitely charge you quite a bit. Expect to spend upwards of $1000. Yeah, ouch. I bet you’re wishing you’d bought that $100 backup drive now, right?

Alrighty, that wraps up Tech Tuesday for this week.

Has anyone seen my holocaust cloak?

Edit: please note, this is merely data recovery 101. There are more advanced things that can be tried, such as using the dd utility to make a backup, booting with a Linux LiveCD for other recovery options, and the like. These topics are somewhat involved, and require more technical savvy than I can impart via a blog post, so suffice to say, if your hard drive just has accidentally baLEETed files and isn’t actually making scary sounds and TestDisk didn’t do as much as you’d hope, drop me a line and I’ll see if I can help. Note, the first thing I will ask you is, “what about your backups?”