locked
HyperV Dualboot WinServer8DP/WinServer2008R2

    Question

  • Hi,

    I have a lab server, on which i have running Windows Server 2008 R2, with HyperV. There are some VMs on it.

    Is it possible to make this setup a dualboot (preferrably by vhd boot for the WS8 installation), and have some way to use the same VM's?

     

    Regards,

    Matthijs ter Woord

    Wednesday, November 16, 2011 8:50 AM

Answers

  •  > Is it possible to make this setup a dualboot (preferrably by vhd boot
     > for the WS8 installation), and have some way to use the same VM's?
     
    Sure, no problem, but you probably want to export the VM's from W2008R2,
    and import (copy) them in W8.  I wouldn't run the exact same VM's if I
    were you, too much chance of a problem.
     
    Here's my instructions for installing into a VHD, it's pretty easy.
    It's for Windows 7 originally, but it still works:
     
    First you have make sure you have a partition on your hard disk that
    has enough free space to put the VHD.
     
    Then while you have your machine set to boot into Win7 or Win2008 R2
    (I think it will work with Vista but I haven't tried -- the bootloader
    gets updated in that case I would think.)
     
    Now boot from the Win8 DVD, select the language and click <next
     
    Then press <Shift<F10 to bring up a command prompt.
     
    Do a DIR on whatever drive letter you suspect that has the room for
    your VHD to verify the drive letter, note that it may be different and
    you might have other drive letters to find it. (the boot loader is
    pretty dumb and assigns drive letters purely sequentially, so it might
    not be the same as your fully booted environment.)
     
    When you found the correct drive letter,
     
    Next, enter these commands:
     
    diskpart
     
    then at the next prompt
     
    create vdisk file=x:\Win7.vhd maximum 60000 type=expandable
     
    select vdisk file=x:\Win7.vhd
     
    attach vdisk
     
    create partition primary
     
    format fs=ntfs label="Win7Boot"
     
    exit
     
    (Where x: is you partition where you want to put the VHD, and 60000
    being the size you want the disk to max out at in megabytes.  (so
    60000 would be 60G.)
     then close the command line shell.
     
    then go on with the installation.  When you get to the screen that
    lists the partitions you can install to, select the one you just
    created above, it should be the last one listed and it'll have a
    different disk id.
     
    You'll get a one line thing that says your hardware can't boot to that
    hard drive but it's bogus, ignore it and continue on with the install.
    When the install is done you should have an entry on your boot menu
    for the new VHD based install.
     
     

    Bob Comer - Microsoft MVP Virtual Machine
    Wednesday, November 16, 2011 2:35 PM

All replies

  • Try this method that is posted for Windows 7 in boot from VHD:

    http://social.technet.microsoft.com/wiki/contents/articles/how-to-boot-from-a-vhd.aspx

    http://technet.microsoft.com/en-us/edge/Video/ff710667

    Try these for Windows 8 and post back your experiance and let us know.

    Wednesday, November 16, 2011 12:14 PM
  • The "boot from vhd" part is very easy and works without any bcdedit calling.

    The problem I'm having, is that I have some existing WinServer2008R2-based HyperV VMs, which i want to run on WinServer8. Probably i can do an export, but that takes a long time..

     

     

    Wednesday, November 16, 2011 12:42 PM
  •  > Is it possible to make this setup a dualboot (preferrably by vhd boot
     > for the WS8 installation), and have some way to use the same VM's?
     
    Sure, no problem, but you probably want to export the VM's from W2008R2,
    and import (copy) them in W8.  I wouldn't run the exact same VM's if I
    were you, too much chance of a problem.
     
    Here's my instructions for installing into a VHD, it's pretty easy.
    It's for Windows 7 originally, but it still works:
     
    First you have make sure you have a partition on your hard disk that
    has enough free space to put the VHD.
     
    Then while you have your machine set to boot into Win7 or Win2008 R2
    (I think it will work with Vista but I haven't tried -- the bootloader
    gets updated in that case I would think.)
     
    Now boot from the Win8 DVD, select the language and click <next
     
    Then press <Shift<F10 to bring up a command prompt.
     
    Do a DIR on whatever drive letter you suspect that has the room for
    your VHD to verify the drive letter, note that it may be different and
    you might have other drive letters to find it. (the boot loader is
    pretty dumb and assigns drive letters purely sequentially, so it might
    not be the same as your fully booted environment.)
     
    When you found the correct drive letter,
     
    Next, enter these commands:
     
    diskpart
     
    then at the next prompt
     
    create vdisk file=x:\Win7.vhd maximum 60000 type=expandable
     
    select vdisk file=x:\Win7.vhd
     
    attach vdisk
     
    create partition primary
     
    format fs=ntfs label="Win7Boot"
     
    exit
     
    (Where x: is you partition where you want to put the VHD, and 60000
    being the size you want the disk to max out at in megabytes.  (so
    60000 would be 60G.)
     then close the command line shell.
     
    then go on with the installation.  When you get to the screen that
    lists the partitions you can install to, select the one you just
    created above, it should be the last one listed and it'll have a
    different disk id.
     
    You'll get a one line thing that says your hardware can't boot to that
    hard drive but it's bogus, ignore it and continue on with the install.
    When the install is done you should have an entry on your boot menu
    for the new VHD based install.
     
     

    Bob Comer - Microsoft MVP Virtual Machine
    Wednesday, November 16, 2011 2:35 PM
  • Hi Bob,

    I hoped there was a way to run the same VM's, but probably you're right, and run the same VM's both under WS2008R2 and WS8 can give issues.. Guess I'll just to have to learn something: patience..

    Thanks for answering!

     

    Regards,

    Matthijs ter Woord

    Wednesday, November 16, 2011 2:39 PM
  • No problem, patients is not one of my strengths either!
     
    I even put the new VM's inside the boot VHD, just so they go away when I
    get rid of the test OS.  It doesn't seem to make all that much
    difference performance-wise, and I always do an import / copy, so I
    don't trash the originals.
     
     

    Bob Comer - Microsoft MVP Virtual Machine
    Wednesday, November 16, 2011 2:58 PM