Would it be effective to run your "main" OS inside a VM?

Let's say I have an i7, 16gb of ram, and a 256gb Crucial M4. My main OS, for reasons, is Windows 7 (on the M4).

Would it be a good idea to install Linux Mint as the host OS on my machine, and make my Windows 7 the guest OS inside Oracle Virtualbox, so I can save state and/or backup easily? (And still do the bulk of my work in the windows os?)

What would be the performance impact of running your main OS inside a virtual machine? Would it be noticeable? I do a lot of things: 3d rendering, video editing, gaming, game development etc..

Also, how is the GPU (videogame) support for virtual machines? I tested certain linux distributions where I worked with CUDA or OpenCL inside VirtualBox, and never seemed to experience any issues. 

The reason I want to do this, is that I hate it when my main OS crashes, or, more often, when a program in it crashes. For example: chrome crashes and it had 200 tabs open, 160 of which I had killed to save memory(leaks); now I have to restart chrome and manually end 160 tabs, because google refuses to be firefox... Or I have a whole bunch of folders open and then for reasons windows explorer crashes and I forget which folders I had open. Or when I'm running UDK and it crashes, etc.. And no, there's nothing wrong with my OS; yes, I am sure.

The point is, I'd love to be able to take snapshots of my OS. And the only way I know to do this is to run it inside a VM. It's also somewhat more secure. But I don't know much about virtualization.


Please shed some light. 

That's actually a good question with more than one answer.

Impact on the CPU: This depends on the speed of your CPU, on the virtualization features and on the hypervisor. Generally you can get up to 90% of raw performance with decend hardware (for both AMD and Intel).

Virtualbox is not the best tool for doing serious work in the VM and you should go with Xen or KVM, imho.

The GPU is a bigger problem because you can't virtualize it. The first solution some smart people came up with was to create a special driver for the client which passes OpenGL calls to the host. This works and is the default technique. Your hypervisor needs to support all APIs you want to useand they're typically extremely slow (<10% of raw speed). To overcome this weakness some other smart people invented VGA passthrough, which is basically a special form of PCI passthrough. This is cool because for the client it looks like it has a PCI device plugged in and it can use whatever driver it wants to use to drive the device (so you can use your normal windows drivers for example), it has the full raw performance of the card and all APIs your client driver supports. The bad news is that 1. you need multiple graphics cards for this to work (but you could use an APU or a onboard graphics card for the host system and pass the external card to the client) and that this is an experimental feature and might require special hardware (you need support on the CPU, the mainboard chipset and the BIOS!) and some not-so-easy tweaking for the software.

http://wiki.xen.org/wiki/Xen_VGA_Passthrough

http://www.linux-kvm.org/page/VGA_device_assignment

Happy hacking! ;)

Did somebody say Happy Hacking?

vbox isent very good its just a free app to try out os'es with limited usage you will need something like vmware workstation to set up a fully working gest machine with (simulated) dedicated hardwhere ram video drives ect 

https://my.vmware.com/web/vmware/info/slug/desktop_end_user_computing/vmware_workstation/9_0

 

Wickedwig, thanks a bunch for providing all that useful info!

I could live with ~90% performance..

Hmm it seems that for now you can only passthrough one videocard, which may be bothersome for rendering if I ever get my hands on something like 2 Titans... :D



It would be totally badass to pull this off though. I'll see what I can do.

 

And in case anyone wonders, you can't just "save the state" of your primary os...

No, you don't need proprietary crap.

Where is the fucking super key?! I can't live without it :(

 http://qubes-os.org/trac

Based on Linux and Xen, virtualizes everything.