Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I have a dual boot machine with Windows 7 and Ubuntu 12.04 LTS. Some time I need Windows 7 during my work. For that I reboot to Windows. It's not a way that I won't access NTFS partition. I need my Windows 7 environment sometime.

Is it possible to boot my Windows 7 partition in virtual machine in Ubuntu 12.04 LTS? That would break me from rebooting. I had heard about Xen and KVM virtual system but don't know how to use.

Any help to use Windows 7 partition on hard disk to boot in virtual box?

share|improve this question
    
The same Windows 7 installation that you have now? –  Mitch Aug 11 '12 at 10:42
    
Yes i have dual boot system. Win7 and ubuntu on single hard disk. I want to use the win7 partition to boot in virtual –  AthloX Aug 11 '12 at 10:44
    
I don't think that is possible. If you need a Windows-environment, you need to login to a windows environment. If there are some applications you need to use, use Wine. –  Akshit Baunthiyal Aug 11 '12 at 10:55
    
I see places that say it is possible with KVM. Has anyone accomplished that? –  flickerfly Sep 30 '13 at 1:14
add comment

2 Answers

up vote 3 down vote accepted
  • Yes, both Virtualbox and VMWare virtual machines will boot from a physical partition provided they are started with the appropriate permissions (gksudo/sudo).

  • The problem lies with Windows, in that its driver settings, particularly for storage devices, are not portable. Unless you modify the Windows registry to force start storage drivers for both the physical and virtual machines, you will mostly likely end up with a 0x0000007B STOP blue screen error each time which will require a restore or modifying the registry to fix.

See this guide for hints on how to do this and troubleshoot 0x7B errors if you want to try (it discusses physical-to-virtual conversions).

share|improve this answer
    
So there is no way to boot win7 partition in ubuntu virtualbox still now, due to windows problem :( –  AthloX Aug 11 '12 at 10:55
    
Unless you know how to force drivers on in the Windows registry, not without significant risk of causing your physical Windows to become unbootable... If you are doing this, I recommend installing Windows from the virtual machine first to a partition... –  izx Aug 11 '12 at 10:57
    
@AthloX: see edit, added a link which may help. But please backup your Windows first... –  izx Aug 11 '12 at 11:15
    
Wow now that's thumbs up @izx. I will surely try this on my scrap machine first and let hit this answer as correct if worked –  AthloX Aug 11 '12 at 11:20
add comment

If all you are looking to do is be able to use your existing Windows environment underneath Linux, what you are looking to do is best served by cloning your setup and migrating it into a VM. At that point, you resolve any registry issues once and only once (and more simplistically). Rather than dealing with the back and forth of drivers between underneath Linux and bare metal, converting it to a true VM will be as if you moved the Windows environment into a new computer. Windows is much more forgiving about that scenario.

How exactly to do it depends on what solution you want to use. Some links for further reading:

  • Disk2VHD - a guide to migrate the Windows install to a VHD file from inside Windows itself. Says it works with VMWare and Virtual Box.
  • VMWare vSphere Converter - VMWare's conversion tool.
  • VirtualBox Guide - VirtualBox's guide to using their conversion tools.

I'm not aware of any way to get it to work using Xen or KVM, but I could very well be wrong about that. VMWare or VirtualBox are most likely perfectly acceptable solutions, however.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.