Unable to install a VM into another VM

23

6

My host computer is running Windows 10, and my guest is Ubuntu in VirtualBox. I am trying to run a 3rd VM on the Ubuntu, but VirtualBox says:

Failed to open a session for the virtual machine Windows XP. VT-x is not available. (VERR_VMX_NO_VMX).

It also returned an error code of 0x80004005

I have virtualization enabled, of course. It's not even an option to turn off in my BIOS (MSI z170a). My machine is very high end, so I know it can run it, I've ruled out everything I can.

SidedTech

Posted 2017-03-06T06:54:40.610

Reputation: 393

4FWIW, KVM can do nested. – Jonas Schäfer – 2017-03-06T10:43:26.010

1From what I remember, a 32-bit inner VM should work, since that doesn't require hardware virtualization (VT-x). Assuming you're interested in 32-bit Windows XP, that should work for you. – CodesInChaos – 2017-03-06T13:27:00.703

4Why nest the Virtualboxes, anyway? – Xen2050 – 2017-03-06T17:04:34.523

4@Xen2050 because, VMception. – David Refoua – 2017-03-06T18:25:49.583

@DRSDavidSoft That was my first though too... SidedTech could've searched for VMception, would've found Can you run a machine emulator (Bochs) inside a virtual machine? which indirectly answers his Q. I would've guessed something like "I had to move my linux install into a VM [for some good reason], but I still want to run my VM's I keep in linux & don't know if just copying config files to win will work & don't want to try"

– Xen2050 – 2017-03-07T06:36:50.213

Answers

45

What you're trying to do is nested virtualization. Its not supported in virtualbox and in no way is a priority for them.

You'll need to run the XP VM in the host instead.

In THEORY you could run plain old QEMU in the VM (it emulates the whole processor and pretty much the whole system) to do this but the performance will be really really bad.

Journeyman Geek

Posted 2017-03-06T06:54:40.610

Reputation: 119 122

The performance of doing that will probably be reminiscent of early PC virtualization solutions (non-hardware-assisted). Think sluggish MS-DOS on modern hardware... – a CVn – 2017-03-06T10:33:20.250

4@MichaelKjörling Why the comparison? Early PC virtualization was hardware-assisted, just not in the same way as today. VMWare used to run ring 0 code in ring 1 with traps on some instructions and other tricks like rewriting kernel code. As far as I remember, VMWare's method was actually a couple % faster than VT-x , when VT-x first came out, according to benchmarks at the time, so not slow at all. Incidentally, running a nested old version of VMWare, or maybe VBox with VT-x disabled on a 32-bit guest might actually work, and work relatively well. Even if I'd only do it out of curiosity. – nitro2k01 – 2017-03-06T11:26:41.900

@nitro2k01When Micheal waid "early" virtualization solutions he meant really early like mid-90s early. Back in those days there was a thing called Virtual PC (later bought by Microsoft) that ran not only on a Mac but on a PowerPC cpu emulating x86. Your VMWare is not early, it is definitely very modern – slebetman – 2017-03-06T13:22:47.833

@slebetman Virtual PC first released in 1997. VMWare first released in 1999, which is also about when I first tried it. The benchmark comparisons to VT-x were of course done much later, but I mentioned it just to show that VMWare's original virtualization method wasn't necessarily slow. The original Virtual PC, despite the name, is not really a virtual machine, but an emulator. – nitro2k01 – 2017-03-06T14:38:21.247

@nitro2k01: AH yes. I remember that. VMWare fusion which also emulated x86 on PowerPC machines. Thank you for reminding me about that. So VMWare, by evidence you yourself provided. Originally really was like how Michael mentioned (notwithstanding the fact that he didn't mention VMWare specifically) – slebetman – 2017-03-06T14:51:16.133

@nitro2k01: Nevermind. Apparently I forgot my history. Fusion was only for Intel Mac. – slebetman – 2017-03-06T14:53:30.013

Early, pre-VT-x VMWare was indeed quite usable. CPU emulations running on a PowerPC Macintosh could be more hardware assisted than you think - that architecture was tailored to emulation, given that it came with a complete 68k emulation system built into the platform... – rackandboneman – 2017-03-06T16:05:49.377

That's weird. I'm on a Windows 7 host, running a Ubuntu guest-host, running a Windows 7 guest, all using VirtualBox. (It doesn't have to make sense; it's a PoC). I have no answer why it doesn't work for the OP, but it should be possible in general. – SQB – 2017-03-07T11:44:27.087

I wonder if bitness matters somehow, or you have a specific set of settings that works. If my answer is wrong, feel free to post a setup that works. I'm always happy to be proven wrong and to learn something new in the process. – Journeyman Geek – 2017-03-07T14:06:15.637