Computers

Solve a Stop 0x0000007B error when booting Vista from physical disk image in VMWare


This post covers the steps you need to take, and gives you pre-packed files to get your Vista virtual machine up and running again after moving the physical disk, or installing it into a different computer for some reason or another. It took me forever to figure this out, reading one too many articles and KB entries so I decided to share.

stop0x0000007b

The problem

I had to upgrade my machine as the previous one wasn’t really coping with my workloads anymore. After much consideration and lack of a good backup (I’ll be covering backup in on of my next post as I’ve finally managed to decide how I’ll go about it :-/ ) I decided the best course of action would be to get a new disk (or two, in my case), and either dual boot or boot the old machine in a VMWare environment. I checked with VMWare (Twitter rocks!) and they said it’s possible but it’s difficult to get it up and running from a physical disk – I thought to myself they’re just saying that. It turns out they weren’t.

Attempt 1: Booting from the physical disk

So, step 1 was to try and boot a virtual machine from the physical disk. It turns out you have to disable the disk, or unmount it (in *nix terms) or you’ll get inconsistency errors. So you open your computer management (Right click on Computer then Manage) and open the Disk Management located under Storage. You select your partition or disk and right click, choosing Change drive letter and paths… Now you have to remove all of the drive letters from this disk.

Manage drive letters

However, I still received inconsistency errors with the disks so I opted to go for another route.

Attempt 2: “Image” the drive

This meant I will create a virtual hard drive image of the physical disk (including any partitions on it). If you have a large disk (I had 320 GB) this could take some time as it’s a sector per sector copy. For this to work, I still recommend unmounting the disk as per first attempt. For the next step get WinImage. Honestly, this little software rocks!

Go to the Disk menu and choose Create Virtual Hard Drive image from Physical Disk… Follow the steps and you’ll get a VMDK image. If you’re only able to get VHD, you can convert it by using Disk > Convert Virtual Hard Disk Image…

Now here comes the tricky part, be sure the disk is IDE! This was key for me. If you convert it with the WinImage it should be done automatically, so no worries there.

NOTE: this might work for SCSI as well, but I haven’t tried it.

Now you create a new Virtual Machine inside VMware and attach the newly created disk to it, set all the parameters and boot up.

Boot Stop Error – Inaccessible Boot Device 0x0000007B

Here’s where the shit really hit the fan. Apparently Windows doesn’t tell you’ve moved it’s disk around and can’t boot drivers – which is logical enough. So I pondered and pondered and read a gazillion articles on how I’ could restore this. I tried the obvious first, I downloaded a Vista DVD from my MSDN Subscription and mounted it in VMware hoping that “Startup Repair” will fix it. It doesn’t.

So here’s what I did to solve it. You’ll need the following:

  • Vista ISO image (if you have a MSDN subscription you can download it) or actual DVD if you want to mount it from VMware

  • A Floppy disk image containing some Registry Information – I’ve packaged my own that you can download, but I won’t guarantee it works. You can make your own by using WinImage to inject this registry file onto it.

  • Some knowledge of how the registry works

If you’re doing this on a bootable machine beware that it can cause your computer to not boot! So know what you are doing!!!!

One of the most informative articles available that actually helped me, was Microsoft KB314082 – You receive a Stop 0x0000007B error after you move the Windows XP system disk to another computer. Obviously the whole article doesn’t apply to the problem of Vista, nor can the suggested solution be used for a non-bootable machine. But this is where I got the mergeide.reg file I’ve uploaded and also the main indication of what to do (which is to use the CriticalDeviceDatabase registry key under the HKLM/System hive).

So, boot into the recovery mode of the Vista install by booting from the DVD and then choosing Repair your computer.

WelcomeToVistaSetup

This will start a wizard that will not find the problem nor fix it. I suggest you cancel it, and select the link that takes you to the Advanced options. Choose Command prompt.

Now, if you’re using my packages from above, you’ll need to load the previous system config into the registry. The installer is its own OS so it has it’s own registry settings. Type in regedit. The registry editor pops up. Now select HKEY_LOCAL_MACHINE and expand it.

RegistryHive1

Now go to File and choose Load Hive… Open C:WindowsSystemConfig (assuming you’re disk is mounted under C: of course, replace the drive if needed) and select SYSTEM. Enter Offline as the name of the loaded Hive. Be careful as this is important for the next step!

Now open the Offline hive you’ve just created and select the folder named Select. Note the number besides Current.

RegistryHive2

With my install it says 1. It will probably be the same with you. Now, we’ll tell windows to ignore what it once knew as the hard drive controllers and use our own files. Load the floppy image you’ve downloaded (or created) into VMware by using it’s settings.

VMFloppy

Be sure to select Connected on the checkbox (I don’t have it checked for a reason!). Now go to File > Import …  and select the .reg file on your diskette inside the Vista image. It should successfully import and viola – you’re Vista is booting inside VmWare!

If you’re going to create your own FLP file, open the registry file (you can download it from me, or from Microsoft) and open it. It should be immediately clear what to replace in order to get it working, if not, either follow my instructions or don’t even attempt to do it!

Vista-Welcome

So there you go, I really hope it helps and that it saves you some time. If you have any questions hit me up on the comments, or on Twitter. Just note I’m not your tech support but  I’ll help if I can! Please make sure you know HOW TO ASK A QUESTION though.


Anže Vodovnik is a proud father, enthusiastic guitarist and passionate software developer. He enjoys presenting at conferences sharing his experience of over 15 years of creating software. He was briefly a Microsoft MVP for Azure before forfeiting the title when he joined Microsoft UK, where he’s now working hand-in-hand with customers to help them develop and use solutions based on the Microsoft Azure platform.

View Comments