It was a high-stakes game, and I won.

Last Updated on September 30, 2010 by Dave Farquhar

Who’s to say where the wind will take you
Who’s to know what it is will break you
I don’t know where the wind will blow
Who’s to know when the time has come around
I don’t wanna see you cry
I know that this is not goodbye
–U2, Kite

When I last left you, I was denying it was time to say goodbye to the data on a friend’s hard drive. I’d found some information on the Internet that promised to get her data back, but I hadn’t done it yet. As often is the case with the Internet, the instructions I found online for doing the job were close. They were not quite right, but they brought me close enough that I was able to make it work.

Removing Form.A from a FAT32 drive is difficult. I was able to verify its presence using the free-for-private-use F-Prot, but F-Prot wouldn’t remove it, Usenet reports to the contrary.

One word of warning: Do as I say, not as I do. The first thing I should have done was make a bit-for-bit backup copy of the drive. I didn’t do that right away. Norton Ghost will work, though it’s not exactly a bit-for-bit copy. A better approach is to get a mini-distribution of Linux and use the standard Unix dd command to make a backup copy. (For example: dd /dev/hda1 /dev/hda2 bs=1024k) Once you have a copy of the drive, work from the copy! If you don’t know how to do all this, do not attempt recovery yourself. It’s much too easy to mess up your drive beyond any hope of recovering your data. This information is presented for informational and entertainment purposes only. I make no representation whatsoever that this will work for you. For all I know it’ll install Gator on your computer and leave the dome light on in your car and erase all your VHS tapes.

I downloaded a utility called ivinit.exe from www.invircible.com (don’t e-mail me if their Web site is down; I could only get to their site about one time out of four myself). It’s a very limited utility; I’d chained the drive off another drive for recovery purposes but ivinit will only work on the primary partition on your C drive. So I disabled the primary drive. Ivinit found it and warned me that the MBR and its mirror didn’t match. I restored the MBR from its mirror, then rebooted. I re-enabled my primary drive, let it boot, and tried to access the drive. I got the invalid media type error again. I ran FDISK, which told me I had a single FAT32 partition. That was a good sign.

So I ran MBRWORK.exe, deleted the MBR and EMBR and told it to recover my partitions. It found a single FAT32 partition. Excellent. I rebooted, tried to read drive C, and… Yeah. Invalid media type paid me another unwelcome visit.

I ran the real-mode version of Norton Disk Doctor from a recent copy of Norton Utilities. You have to be very careful with Norton Disk Doctor; never run it unless you’re positive the version you have knows about FAT32. Otherwise, you’re setting your hard drive up for a train wreck. NDD wasn’t too happy. It wanted to scavenge and rebuild the partition table, and it didn’t offer me a chance to make a backup copy. I never let a low-level utility do anything that it won’t let me undo. I aborted.

At this point I wised up. I put an Intel 10/100 network card in the PC I was using to recover the data, plugged into my network, grabbed my magic network boot disk, and connected up to the big Windows 2000 computer I use for editing video. I ran Norton Ghost and told it to make an image of the disk. To my amazement, it found a single 3.8-gig FAT32 partition and started running through filenames!

Like I said, Ghost doesn’t normally do a bit-for-bit copy; it stores enough information to recreate a valid copy of your partition. If your partition isn’t quite valid, that means you don’t get an exact copy. The upside of that is that Ghost can be a useful data recovery tool, assuming it can make sense of your partition. And fortunately, it looks like it’ll make sense of partitions that Windows itself doesn’t want to touch.

Theoretically, I could have restored the data by just making an image with Ghost, then restoring the image immediately afterward.

Norton Disk Doctor revived the partition, and it revived it more quickly than a Ghost restore would have. Then I ran into another pitfall–everything in the root directory appeared OK, and most subdirectories one level deep were fine, but anything nested gave sector not found errors. Norton Disk Doctor offered to fix that stuff, but I had a gut feeling that I shouldn’t go that route. Any time there’s the possibility of bad sectors, I want SpinRite.

As soon as I ran SpinRite, it reminded me of why I should bring it into the game as quickly as possible. It reported that the drive’s CMOS parameters appeared incorrect and it was hesitant to continue. That’s good–incorrect CMOS parameters can cause the problems I was seeing. And trying to repair the drive with messed up CMOS parameters will lead to nothing good–something that Steve Gibson is certainly aware of, and something that Symantec may not necessarily care about. In this case, the parameters were wrong because I put the drive in another system and it defaulted to a different addressing method. Whenever you’re doing data recovery and you want to move the drive, you need to be sure you get addressing straight or you’ll do a whole lot more harm than good.

After I corrected the CMOS, a simple DIR /W /S ran through the entire drive with no complaints. Norton Disk Doctor found no filesystem errors or low-level errors. SpinRite doesn’t do anything about filesystem errors, which is why I went back to NDD–use NDD when you suspect filesystem problems, but always always turn surface-scan-type stuff over to SpinRite. And there’s no harm in running SpinRite first–it’ll alert you to problems that NDD might not notice.

Along the way I learned a whole lot more than I ever wanted to know about boot-sector viruses. AntiCMOS and Form were able to coexist together nicely, and on just about any computer purchased new between 1992 and 1996, they’d just happily infect any disk you used and you’d probably never be the wiser. With the release of Windows 95B and FAT32, Form became destructive. (Why should Microsoft test new filesystems for compatibility with old viruses?) Wendy told me the problem appeared after she left an old disk in the computer before she booted it up. I suspect their old computer picked up the virus at some point, and since it wasn’t destructive under DOS and Windows 3.1, they never noticed. The computer just happily infected disks. Boot sector viruses flourished in the early 90s, as everyone needed a boot disk to play Doom or other tricky DOS games, so people traded boot disks like recipes. As often as not, those boot disks carried viruses.

When I went to put the drive back in, the dreaded “Operating system not found” paid me a visit. I hadn’t wanted to try to boot off the drive while it was in another PC for obvious reasons. So I did the standard drill. First up: fdisk /mbr. Strikeout. Second: sys c:. Strikeout. Finally, God reached down with His two-by-four and smacked me upside the head to knock some sense into me. I ran plain old fdisk and found the problem–no active partition. So I set the partition to active, and boom. The system booted up and was its old self again. It seems like I always make that mistake.

Data recovery is definitely a trade or a skill, not a science or process.

If you found this post informative or helpful, please share it!