Page 1 of 1

Nested VM on Windows 7?

Posted: 4. Jul 2013, 18:00
by Hiro Protagonist
I have VBox 4.2.14 installed on Windows 7, and have Ubuntu 10.04 as a guest within it. Inside the guest I have installed the Linux version of VBox 4.2.14 and have managed to install Windows 98 inside that. However, when I start the Windows 98 I get the startup splash screen, then it goes back to a blank text-mode display with a flashing cursor on the top left, and that's as far as it gets. If I reset the inner Win98 VM and restart in safe mode, it comes up with "Safe Mode" in every corner of an otherwise blank desktop. Right-clicking get me the Display Settings dialog box (eventually) but apart from resetting the display from 640x480x16 to 640x480x16 (!) this doesn't really get me anywhere.

The actual hardware I'm running on is a Celeron 900 (which has no VT-x or EPT support or anything else).

Has anyone any idea whether (a) this is possible, and (b) why it might be hanging?

TIA...

Re: Nested VM on Windows 7?

Posted: 4. Jul 2013, 18:08
by mpack
It may not be hanging, it might just be incredibly slow, as Win98 sometimes is when run directly on the host VirtualBox. VT-x sometimes helps, but that isn't available to a nested VM. If in safe mode you get to a blank screen with "Safe mode" in all four corners then that does indeed sound like it got most of the way through a boot.

By the way: nested VMs are not supported, neither is Win98 for that matter, so your chances of getting the devs interested in this are rather small I suspect. I'm kind of surprised you got this far, as I would have expected that it only works even that much when the host has VT-x.

Re: Nested VM on Windows 7?

Posted: 4. Jul 2013, 20:24
by Hiro Protagonist
I was quite surprised too -- but pleasantly so, as I wanted to try and do a demo for an introductory talk about VMs which involved this kind of madness. I understand that nested VMs are possible with VMWare, but it means trying to set it up so that the demo is within the 30 day trial period...

Meanwhile I've read that VBox doesn't support 9x at all... and installing 9x directly on Windows 7 (the real system running on the real hardware) doesn't even get past the splash screen after it installs, so the nested emulation is actually better than the unnested version in this case!

All the stuff i read about nested VMs is a bit old; maybe 4.2.14 does things in a way which gives it a fighting chance of working. So before I get stuck into VMWare, I'm going to have another go with Win NT or 2K... you never know if things will work until you try them, even if everyone else tells you they won't!

Re: Nested VM on Windows 7?

Posted: 4. Jul 2013, 21:15
by Hiro Protagonist
Incidentally, here is a screenshot showing Win98 starting up inside Ubuntu inside Windows 7...
vbox.jpg
vbox.jpg (106.64 KiB) Viewed 1702 times

Re: Nested VM on Windows 7?

Posted: 5. Jul 2013, 09:43
by Hiro Protagonist
So, just to conclude, I managed to get it working by disabling sound & USB support in the Win98 box. Here, just for fun, is a screenshot of Windows 7 running Ubuntu running Windows 98 running an Apple II emulator running Super Mario Bros... albeit quite slowly...!
Windows 7 running Ubuntu running Windows 98 running an Apple II emulator running Super Mario Bros
Windows 7 running Ubuntu running Windows 98 running an Apple II emulator running Super Mario Bros
vbox.jpg (49.2 KiB) Viewed 1689 times

Re: Nested VM on Windows 7?

Posted: 5. Jul 2013, 10:44
by mpack
Win9x is not officially supported (e.g. there are no GAs, and unlikely there ever will be), but this is not the same as saying that it won't work. I have a Win98 VM on my own PC, in fact I've had it for a long time. It used to run at a decent speed but then around VBox v4.0 it suddenly got very very slow, taking minutes to boot up. However once booted up it was kind of ok (not great). However I found that if I enabled VT-x then boot time and general performance was very good. I appreciate that VT-x is not available on your current hardware.

I hope that in your talk you'll mention the difference between a simulator, e.g. your Apple II simulator (I used to use an Apple II btw) - and a hypervisor. We still get people coming here asking if they can run PowerPC code, or might they compile VirtualBox Open Source Edition for an Android/ARM7 platform and then install XP?

Re: Nested VM on Windows 7?

Posted: 5. Jul 2013, 12:52
by Hiro Protagonist
mpack wrote:I hope that in your talk you'll mention the difference between a simulator, e.g. your Apple II simulator (I used to use an Apple II btw) - and a hypervisor. We still get people coming here asking if they can run PowerPC code, or might they compile VirtualBox Open Source Edition for an Android/ARM7 platform and then install XP?
Yes, the Apple II emulation is a way in to talk about hardware assistance for VMs -- how Apple II emulation in software is feasible because it's such an old machine, and a pure software emulation on a modern machine is faster than the original hardware, but how you need help from the hardware if you want to run a modern system in a VM with acceptable efficiency.

Re: Nested VM on Windows 7?

Posted: 5. Jul 2013, 13:16
by mpack
Hiro Protagonist wrote:but how you need help from the hardware if you want to run a modern system in a VM with acceptable efficiency.
And more specifically: that a hypervisor does not emulate a CPU, instead (with a few exceptions) code runs at full speed on the host processor. Only peripheral hardware is emulated. Therefore you cannot run e.g. a VirtualBox XP VM on an Android/ARM7 platform even if you did port the VirtualBox source code.