First attempt at nested virtualization

Author: | Posted in other No comments

Standard virtualization uses the physical machine Nested VMs as the host hypervisor which allows one to install virtual machines called guests. In nested virtualization the hypervisor is also a guest running inside a virtual environment and it can host its own virtual machines. Basically nested virtualization allows one to install a VM inside a VM.

Some people have reported some success with KVM, but I couldn’t find anything on VirtualBox (besides the usual “it’s not supported”), so I decided to give it a try.

In short it didn’t work, so this is not a success story, but I got further than I expected. I was able to install a VM inside a VM and it even booted up to a point where it stopped responding. Here’s my setup:

  • physical machine:
Red Hat Enterprise Linux Server release 6.4 (Santiago)
8GB of RAM
  • virtual machine #1 (VM1):
Fedora release 18 (Spherical Cow)
4GB of RAM
  • virtual machine #2 (nested VM i.e. VM2):
Red Hat Linux 6.2 (not RHEL, but the old RH distro which was the only 32-bit ISO I had available, the default setup only allowed me to install a 32-bit OS)
1GB of RAM

The nested VM installed fine and it booted properly up to a point where the VirtualBox kernel modules become tainted on VM1. Fortunately VM1 didn’t freeze so I was able to force a poweroff of VM2:

VBoxManage controlvm "Red Hat 6.2" poweroff


Below some screenshots with the installation and booting process.

No Responses

Add Your Comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.