Page 2 of 3 FirstFirst 123 LastLast

  1. Joined : Jun 2015
    Posts : 1,604
    Windows 3.1 to Windows 10
       19 Apr 2016 #11

    Attach the drive with the VHD file to any windows 8/10 PC

    I assume the .VHD(X) file is on an external USB drive.... we'll example it as drive letter USB:\

    Mount the .VHD(X) file ... we'll example it as drive letter VHD:\

    Then from that PC, open command prompt (admin)

    if mounted x86 VHD - use cmd > bcdboot VHD:\Windows /s USB: /f BIOS
    if mounted x64 VHD - use cmd > bcdboot VHD:\Windows /s USB: /f ALL

    The above will write the files required to boot the VHD to the external drive...
    then just set the external drive as your Boot device, to boot the windows vhd..
      My System SpecsSystem Spec


  2. Joined : Apr 2016
    Posts : 2
    OpenSUSE / Win 7
       19 Apr 2016 #12

    Kyhi said: View Post
    if mounted x86 VHD - use cmd > bcdboot VHD:\Windows /s USB: /f BIOS
    if mounted x64 VHD - use cmd > bcdboot VHD:\Windows /s USB: /f ALL
    Exactly what i was looking for. Brilliant, thank you.
    And your procedure for converting and deploying the image described earlier worked as a charm.

    This will help me a lot in the future. (If your'e not allready getting paychecks from Microsoft they should start sending them )
      My System SpecsSystem Spec


  3. Joined : Jun 2015
    Posts : 1,604
    Windows 3.1 to Windows 10
       19 Apr 2016 #13

    Just glad I could help..
      My System SpecsSystem Spec


  4. Joined : Aug 2015
    Posts : 8
    Windows 10
       14 Aug 2016 #14

    Kyhi said: View Post
    Attach the drive with the VHD file to any windows 8/10 PC

    I assume the .VHD(X) file is on an external USB drive.... we'll example it as drive letter USB:\

    Mount the .VHD(X) file ... we'll example it as drive letter VHD:\

    Then from that PC, open command prompt (admin)

    if mounted x86 VHD - use cmd > bcdboot VHD:\Windows /s USB: /f BIOS
    if mounted x64 VHD - use cmd > bcdboot VHD:\Windows /s USB: /f ALL

    The above will write the files required to boot the VHD to the external drive...
    then just set the external drive as your Boot device, to boot the windows vhd..
    Hello. I'm also trying to boot to a VHDX file from a USB drive.

    I successfully did the steps above (for x64). However when I reboot, the VHDX is no longer attached! Is there a way to attach the VHDX prior to selecting it from the boot menu?
      My System SpecsSystem Spec


  5. Joined : Jun 2015
    Posts : 1,604
    Windows 3.1 to Windows 10
       14 Aug 2016 #15

    Explain where the VHD file is located
    and where you wrote the boot files

    You also have to be booting in Legacy mode (legacy support enabled) - if using a usb stick...
    as uefi booting would require an partitioned drive

    no need to pre-attach (mount) VHD in order to boot it..
      My System SpecsSystem Spec


  6. Joined : Aug 2015
    Posts : 8
    Windows 10
       14 Aug 2016 #16

    Kyhi said: View Post
    You also have to be booting in Legacy mode (legacy support enabled) - if using a usb stick...
    as uefi booting would require an partitioned drive

    no need to pre-attach (mount) VHD in order to boot it..
    I think the above is the cause of my issue.

    First off, the VHDX file is located on a 'WD MyBook' drive which is attached via a USB port. And I do see UEFI in my boot menu (next to some, but not all, boot options).

    So basically, what is UEFI and is it possible for me to enable legacy mode? (I'll do some digging around on this myself, too).

    In addition, when I executed your commands my USB drive was mapped to drive W and the VHDX file (located on that same drive) was mounted to drive H.

    EDIT: I can see that legacy mode is enabled for the USB drive and so I'm guessing that looks ok. Could my problem be that my VHDX was created from a 'UEFI Windows 10' install and it somehow needs to be modified to be a 'Legacy Windows Install'?
    Last edited by Day Trooper; 14 Aug 2016 at 22:18.
      My System SpecsSystem Spec


  7. Joined : Dec 2015
    Posts : 2,429
    Windows10
       15 Aug 2016 #17

    You could try this but be warned it might not work due to driver issues.

    Copy vhdx file to say c:\vhd folder as say win10.vhdx

    Then boot from a windows 10 installation usb drive

    Then, select language etc, and at install now screen, press shift+f10

    Then enter these commands

    diskpart

    select vdisk file=c:\vhd\win10.vhdx

    attach vdisk

    exit

    exit

    Remove installation usb drive and reboot. You will now be able to boot from vhdx.

    With luck it will boot but you might get driver issues. If so, installing vhdx in a vm is more likely to work.
      My System SpecsSystem Spec


  8. Joined : Aug 2015
    Posts : 8
    Windows 10
       15 Aug 2016 #18

    cereberus said: View Post
    Then enter these commands

    diskpart

    select vdisk file=c:\vhd\win10.vhdx

    attach vdisk
    Thanks for the reply. I was able to attach my VHDX, but unfortunately after rebooting the VHDX is no longer attached.

    Any other ideas?
      My System SpecsSystem Spec


  9. Joined : Dec 2015
    Posts : 2,429
    Windows10
       15 Aug 2016 #19

    Day Trooper said: View Post
    Thanks for the reply. I was able to attach my VHDX, but unfortunately after rebooting the VHDX is no longer attached.

    Any other ideas?
    Sorry my brain was not in gear - I forgot to mention the bcdboot commands needed

    When running diskpart after attaching vhd, you have to find the volume that contains the system reserved (legacy bios) or efi partition (uefi), and assign a drive letter to it temporarily.


    in diskpart still, run

    list vol

    and you get something like

    Volume 0 C 10 Pro N NTFS Partition 195 GB Healthy Boot
    Volume 1 E Data NTFS Partition 735 GB Healthy
    Volume 2 FAT32 Partition 329 MB Healthy System
    Volume 3 NTFS Partition 465 MB Healthy Hidden
    Volume 4 F Disk 2 NTFS Partition 471 GB Healthy
    Volume 5 G Disk 2 NTFS Partition 459 GB Healthy
    Volume 6 D 10 Home NTFS Partition 149 GB Healthy

    Here volume 2 is mine - it is the FAT32 volume

    To assign drive letter still in diskpart:

    select volume 2 (in my case)

    assign letter=s (could be any letter but I use S for system)

    Here volume 6 is my vhd attached as per earlier command and is drive D in my case

    Then you exit diskpart and type

    bcdboot d:\windows /s s: /f uefi (or bios as appropriate)

    See step 4 in this guide.

    Boot to VHD (Native Boot): Add a Virtual Hard Disk to the Boot Menu
      My System SpecsSystem Spec


  10. Joined : Dec 2015
    Posts : 2,429
    Windows10
       15 Aug 2016 #20

    Kyhi said: View Post
    Explain where the VHD file is located
    and where you wrote the boot files

    You also have to be booting in Legacy mode (legacy support enabled) - if using a usb stick...
    as uefi booting would require an partitioned drive

    no need to pre-attach (mount) VHD in order to boot it..
    Good to see you back. Hope things are going ok with you.
      My System SpecsSystem Spec


 
Page 2 of 3 FirstFirst 123 LastLast


Similar Threads
Thread Forum
Solved Can't native boot Hyper-V generation 2 vhdx
If I create a generation 1 VM I can native boot the vhdx by adding bcd entry. If I make a generation 2 VM it fails with "a required device isn't connected...0xc0000225". Pressing f8 for "Startup Settings" gives "The application or operating system...
Virtualization
Solved How do I open a VHDX file?
Using Windows 10-64 and Windows backup and restore. I want to view a file that must be contained in a recent backup. I see the apparent backup files as vhdx. I right click to mount the virtual HD and get an error message as shown in the screenshot....
Virtualization
Solved Hyper-v guest internet connection lost after booting as VHDX.
Hello, I am running Windows 10 Pro (10240) and have a guest Windows 10 VM (10528) which were working fine. Both were activated and connected to internet correctly. Today I booted the VM as native boot VHDX. This installed some drivers,...
Virtualization
Install Win 10 on new computer build and keep old computer running
I am in the process of building a new PC. After updating the old existing Win 7 32 bit desktop to Win 10, can I do a clean Win 10 64 bit install on the new build and keep the old computer running while I install all the necessary programs and...
Installation and Setup
Solved How to release unused space in VHDX disks?
Before I learned that VHDX expanding disks do not release space, many of these have swelled way beyond what is used of needed because I did a defrag. Defrag will use temporary space to store files parts being defragged. I expected defrag to make...
Virtualization
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 19:13.
Find Us
Twitter Facebook Google+



Windows 10 Forums