Virtualization

 View Only
  • 1.  How To Create Nested Virtualization Using Hyper-V In The Guest?

    Posted Jan 04, 2015 08:13 AM

    Hi,

    I try to do nested virtualization with VMware Player v7 and Windows Server 2012 R2 as the guest but fail to install the Hyper-V role.

    According to this VMware document, it's possible to run a VM within a VM with Player 7: "Virtualized HV is fully supported for virtual hardware version 9 or later VMs on hosts that support Intel VT-x and EPT or AMD-V and RVI. To enable virtualized HV, select VM->Settings and navigate to the processor settings screen. Check the box next to  "Virtualize Intel VT-x/EPT or AMD-V/RVI."“

    First, I tried on 2 different computers (1 server running Windows Server 2008 R2 and 1 laptop running Windows 7 Pro) whose CPU support "Intel® VT-x with Extended Page Tables (EPT)" according to Intel's official website:

    Second, in the VM CPU settings, I tried the following options:

    In each case, when I try to add the Hyper-V role in the guest, it fails with the message "Hyper-V cannot be installed: A hypervisor is already running":

    I also tried using VMware Workstation 11 instead of Player 7 but it's the same.

    Can someone tell me what's wrong? How can I do nested virtualization using Hyper-V in the guest?

    Thanks in advance.



  • 2.  RE: How To Create Nested Virtualization Using Hyper-V In The Guest?

    Posted Jan 04, 2015 01:28 PM

    Did you set the guest OS type to "Hyper-V"?



  • 3.  RE: How To Create Nested Virtualization Using Hyper-V In The Guest?
    Best Answer

    Posted Jan 05, 2015 03:27 AM

    Hi WoodyZ,

    No, I didn't and after further search on Internet, I found 2 solutions for my issue.

    Solution #1: (the most simple one)

    Set the guest OS type to "Hyper-V (unsupported)". In my case, my guest OS is Windows Server 2012 but I suppose you have to choose this option whether you run Windows Server 2012, Windows Server 2008 or Windows 8/8.1.

    The VM's CPU settings won't change:

    Solution #2:

    If you don't set your OS type to "Hyper-V (unsupported)":

    • Open the file Location for this Virtual Machine, open the file extension (*.vmx) with Notepad.
    • In the last line, add this code and save it:

            hypervisor.cpuid.v0 = “FALSE”

            mce.enable = “TRUE”

            vhu.enable = “TRUE”

    • After that, edit the CPU settings on VM from VMware Workstation/Player by checking the following options:

             Virtualize Intel VT-x/EPT or AMD-V/RVI.

            Virtualize CPU Performance counters.

    Source: http://social.technet.microsoft.com/wiki/contents/articles/22283.how-to-install-hyper-v-on-vmware-workstation-10.aspx

    You will then be able to add the Hyper-V role in the guest OS.



  • 4.  RE: How To Create Nested Virtualization Using Hyper-V In The Guest?

    Posted Jan 05, 2015 10:59 AM

    Just a quick note, although you got this already fixed. As of VMware Workstation 9/Player 5, setting the guest OS to "Hyper-V" (as mentioned by WoodyZ) should be sufficient. For details see Running Nested VMs.

    André



  • 5.  RE: How To Create Nested Virtualization Using Hyper-V In The Guest?

    Posted Jan 06, 2015 03:50 AM

    Thanks a.p. for your explanation.

    A bit out of topic, but is VMware the only product on the market that supports nested virtualization?



  • 6.  RE: How To Create Nested Virtualization Using Hyper-V In The Guest?

    Posted Jan 06, 2015 01:27 PM

    So far I only used VMware products to run my nested labs. However, this may certainly be possible with other Hypervisors too.

    I moved your discussion from VMware Player to Nested Virtualization so maybe other users who run such environments will comment on this.

    André



  • 7.  RE: How To Create Nested Virtualization Using Hyper-V In The Guest?

    Posted Jan 06, 2015 01:54 PM

    CuiZinieR wrote:

    Thanks a.p. for your explanation.

    A bit out of topic, but is VMware the only product on the market that supports nested virtualization?

    No; Xen and kvm both support nested virtualization.



  • 8.  RE: How To Create Nested Virtualization Using Hyper-V In The Guest?

    Posted Oct 22, 2015 10:32 AM

    There's also Parallels that allows you to use a hyper-visor inside a virtual machine. Tested.



  • 9.  RE: How To Create Nested Virtualization Using Hyper-V In The Guest?

    Posted Jan 06, 2015 01:58 PM

    CuiZinieR wrote:

    In my case, my guest OS is Windows Server 2012 but I suppose you have to choose this option whether you run Windows Server 2012, Windows Server 2008 or Windows 8/8.1.

    Once you install the Hyper-V role in the guest, the guest OS becomes Hyper-V.  The management OS is irrelevant, since it runs in a nested VM under Hyper-V.  We don't distinguish among Hyper-V R1, Hyper-V R2 and Hyper-V R3, since the VM configuration settings are the same for all three.



  • 10.  RE: How To Create Nested Virtualization Using Hyper-V In The Guest?

    Posted Jan 07, 2015 09:24 AM

    Thanks jmattson for your comments!