Page 1 of 1
Migrate Windows 7 VirtualBox Guest to Boot Camp?
Posted: 24. Sep 2011, 02:11
by DiGiTY
How do I migrate Windows 7 VirtualBox Guest to Boot Camp (essentially V2P, virtual to physical)?
Thanks in advance
Re: Migrate Windows 7 VirtualBox Guest to Boot Camp?
Posted: 28. Sep 2011, 06:49
by DiGiTY
I dove into it and figured it out myself. I used ShadowProtect Recovery Disc (3.5) to image the virtual Windows 7 installation on VirtualBox and restored it to the Boot Camp partition. I couldn't boot into Windows by holding down the option key upon machine boot up (even though Windows 7 was on the partition and selectable from the Startup Disk control panel in Mac OS X) and this may be due to the fact I unchecked all the restore options, including the write MBR options, in ShadowProtect when restoring the image (I read somewhere that was the thing to do). Not realizing I could of fixed this problem by re-restoring with the MBR options checked I proceeded to install a fresh installation of Windows 7 on the Boot Camp partition thinking it'll then properly write the MBR and I can re-restore the image (again with all restore options unchecked). I was correct, it was selectable when holding down the option key upon machine boot up, and it booted Windows 7... then blue screened.
I was getting the BSOD error 0x0000007B (inaccessible device). Researched and found out the hard drive drivers installed on the Windows 7 image were for a different type of hard drive than the hard drive used on Boot Camp (probably IDE vs. SATA/AHCI) and this caused Windows to blue screen. The solution lied in setting Windows up to forget about the hard drive drivers its currently set to use and search & install the device drivers for the new system upon boot. This involved making changes to the Windows 7 registry. After following the instructions below I was able to boot Windows 7, install all the Boot Camp hardware drivers (updated some drivers manually like for the Nvidia graphics card) and end 3 days of headache.
So to recap...:
[1] Clone your VB installation of Windows 7 with your cloning tool of choice (Drive Snapshot is free and should work just as well)
[2] Restore it to the Boot Camp partition with write MBR options enabled (if that doesn't work, install a fresh Win7 and re-restore over that with write MBR options disabled)
[3] If you get 0x0000007B BSOD error then follow the instructions below to resolve it and get Windows 7 booting and properly migrated
[4] When finally booted into Windows insert your Mac OS X installation disc and run the Boot Camp installer to install all the necessary drivers for your Mac hardware
Hope this is helpful to someone! The fix below may apply to any kind of Windows Vista or 7 migration that gets the 0x0000007B error (V2P, P2V, P2P, V2V, etc.)
Fix for BSOD 0x0000007B Error
---
[1] Boot from the Windows 7 installation disc in the affected machine (i.e., the machine that's experiencing the 0x0000007B error)
[2] At the first screen (Language Selection), hit Shift-F10 for a command prompt
[3] Type "regedit" (without the quotes) and hit enter
[4] Load the system hive from the affected machine:
[-] Select the HKEY_LOCAL_MACHINE branch
[-] Go to the File menu and select "Load Hive"
[-] Load the file "system" in Z:\Windows\System32\config\ where Z: is the drive letter of the drive/partition with the affected Windows installation
[-] When prompted, name it something like "asdf" (the name doesn't matter, its just a placeholder)
[-] Expand to HKEY_LOCAL_MACHINE\asdf\ControlSet1\Services\
[-] For each of the sub-branches listed below change the value for key labeled "Start" to "0" (without the quotes):
* All of these sub-branches are listed to cover all bases. You may only need to change the key for one or two of these (likely intelide and/or msahci) *
Aliide
Amdide
Atapi
Cmdide
iaStorV
intelide
msahci
pciide
viaide
[-] When done making the changes, go to the File menu and select "Unload Hive"
[-] Exit Regedit
[-] Restart the machine and you should be able to boot the affected Windows machine without the 0x0000007B error (it'll take a little longer than usual to start up because its installing those device drivers in the background).
Re: Migrate Windows 7 VirtualBox Guest to Boot Camp?
Posted: 2. Oct 2011, 10:41
by Zlika
Hello.
A big thank you for posting this.
I have a dead PC which I very much wanted to use, and your tip helped me to virtualize it --the PC was dead but the hard disk still working.
I'm still struggling with after-login BSOD, but I'm confident your tip brought me more than halfway !
FWIW : in my situation, all changes I made to ControlSet001 were mysteriously undone soon as I unloaded the hive (reloaded it to check...)
It turns out that I had to modify entries within ControlSet002 (to be on the safe side I also modified them under ControlSet001 after making sure they were saved) to get the thing to work.
Thanks again,
Z.
Re: Migrate Windows 7 VirtualBox Guest to Boot Camp?
Posted: 17. May 2012, 20:19
by sabotuer99
BA-BAM! I was fighting to get an imaged copy of Win 7 to boot as a guest and your post finally got me booted up. THANK YOU! Now if I can just fix the new BSOD...