Recommended Posts

I was recently asked how to setup a Windows To Go installation that can boot from both UEFI and BIOS PCs with non certified devices.

All the guides I found to do this online are compatible with either BIOS or UEFI but not both.

The reason is because compatibly with both needs 2 partitions so most usb keys wont work

IC611726.gif

So you need either a USB HDD or a USB Key that shows up as a Fixed Disk.

If you cant get your device to pass-through into HyperV its not a Fixed Disk and wont work

http://blogs.technet.com/b/askcore/archive/2008/10/24/configuring-pass-through-disks-in-hyper-v.aspx

Im going to test this using HyperV the only difference between this and creating a real device is changing the drive letters and numbers in diskpart.

rWfK4VO.png

Start by creating two VMs a Gen 1 and a Gen 2 VM both with the same VHD File

xFKXZi3.png

Now boot from the Windows CD on the Gen1 VM as the Gen2 VM will complain about not installing to a GPT disk.

5abPIXS.png

At the install screen press shift + f10 to open command prompt and run notepad to get a GUI file explorer window when you select file > open

ZZP8DPI.png

Convert the disk to MBR format and create 2 partitions a Fat32 system partition marked as active and a NTFS windows partition.

llzrKsp.png

Apply any windows image to the windows partition

llzrKsp.png

Which creates the standard windows folder structure

crOgMNF.png

Use the BCDBOOT command to copy the boot files for both UEFI and BIOS computers from the Windows partition to the Fat32 system partition

MaFjsZG.png

Eject the windows iso and let the Windows To Go drive boot.

iQ4XcKU.png

Complete OOBE

G3R9clc.png

Install whatever software you need

ZeQGQk8.png

Shutdown to test the image on a UEFI Secure Boot PC

cueP5HG.png

Start-up the UEFI PC and the Windows To Go drive boots

NxL5f4A.png

The same user profile now starts up on an entirely different articheture.

Code used

diskpart
select disk 0
clean
convert mbr 
create partition primary size=350
format quick fs=fat32 label="System"
Active
assign letter="S" 
create partition primary
format quick fs=ntfs label="Windows To Go"
assign letter="W"
exit

Dism /apply-image /imagefile:E:\sources\install.wim /index:1 /ApplyDir:W:\

bcdboot w:\Windows /s S: /f ALL
Sources

https://technet.microsoft.com/en-ie/library/jj592685.aspx

https://technet.microsoft.com/en-ie/library/hh825677.aspx

  • Like 2
  • 3 weeks later...
  • 1 year later...

THIS IS EXACTLY WHAT I'M TRYING TO DO! I want to make a windows to go that can be booted on my desktop using BIOS, as well as my surface pro 3 using UEFI. Thank you, this guide is awesome! 

I do have a couple questions though. How do I "use the BCDBOOT command to copy the boot files for both UEFI and BIOS computers from the Windows partition to the Fat32 system partition"?

Would both of those be on my surface pro, or would I need to copy it from my desktop, then from my surface? Please explain it to me like I'm a novice... because I am.

This guide is a little vague on that step... actually its kinda vague in general (but its still awesome).

6 minutes ago, WIRM.KJones said:

THIS IS EXACTLY WHAT I'M TRYING TO DO! I want to make a windows to go that can be booted on my desktop using BIOS, as well as my surface pro 3 using UEFI. Thank you, this guide is awesome! 

I do have a couple questions though. How do I "use the BCDBOOT command to copy the boot files for both UEFI and BIOS computers from the Windows partition to the Fat32 system partition"?

Would both of those be on my surface pro, or would I need to copy it from my desktop, then from my surface? Please explain it to me like I'm a novice... because I am.

This guide is a little vague on that step... actually its kinda vague in general (but its still awesome).

No, you should do the initial setup in a virtual machine to avoid the risk of messing up the BCD on the pc.

 

Create a virtual machine and passthrough the disk that you want to use for windows to go (if it is using hyperv you need to offline the disk in disk management)

 

Then add a Windows iso to the virtual dvd drive and power the VM on.

 

It should boot from the DVD and once it does you can press shift + F10 to open the command prompt where you can paste in the code and it will do everything.

 

The bcdboot command is

 

bcdboot w:\Windows /s S: /f ALL

 

W:\Windows is where windows was just installed using DISM

/s S: is where the system partition is mounted

 

and /f ALL is what tells bcdboot to copy all the boot files not just whats needed at the moment.

  • Like 1
1 hour ago, TPreston said:

No, you should do the initial setup in a virtual machine to avoid the risk of messing up the BCD on the pc.

 

Create a virtual machine and passthrough the disk that you want to use for windows to go (if it is using hyperv you need to offline the disk in disk management)

 

Then add a Windows iso to the virtual dvd drive and power the VM on.

 

It should boot from the DVD and once it does you can press shift + F10 to open the command prompt where you can paste in the code and it will do everything.

 

The bcdboot command is

 

bcdboot w:\Windows /s S: /f ALL

 

W:\Windows is where windows was just installed using DISM

/s S: is where the system partition is mounted

 

and /f ALL is what tells bcdboot to copy all the boot files not just whats needed at the moment.

Once again, thank you so much for your help! I'm sure this whole procedure is pretty cut and dry, but its still just a little enigmatic to me... But like I said, when it comes to this kind of stuff, my experience is a little inchoate. 

So another question (it probably has a really obvious answer), how do I make a virtual machine?

1 minute ago, WIRM.KJones said:

Once again, thank you so much for your help! I'm sure this whole procedure is pretty cut and dry, but its still just a little enigmatic to me... But like I said, when it comes to this kind of stuff, my experience is a little inchoate. 

Do another question (it probably has a really obvious answer), how do I make a virtual machine?

Here is a quick guide

 

https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows/quick-start/quick-create-virtual-machine

8 hours ago, TPreston said:

So I enabled Hyper-V Manager on my computer, and I'm in the process of making the two VM. The step where it states "make the two VM share the same VHD file", does that mean the that I need to make them share the same name when I create a virtual hard disk? 

6 minutes ago, WIRM.KJones said:

So I enabled Hyper-V Manager on my computer, and I'm in the process of making the two VM. The step where it states "make the two VM share the same VHD file", does that mean the that I need to make them share the same name when I create a virtual hard disk? 

It depends how many devices you are looking to provision if its just one drive then you are better off just making it a pass through drive on both VMs (only one can be started at the same time)

 

http://thesolving.com/virtualization/how-to-configure-a-pass-through-disk-with-hyper-v/

57 minutes ago, TPreston said:

It depends how many devices you are looking to provision if its just one drive then you are better off just making it a pass through drive on both VMs (only one can be started at the same time)

 

http://thesolving.com/virtualization/how-to-configure-a-pass-through-disk-with-hyper-v/

I'm really sorry, I'm trying really hard to absorb all of this information and to do it quickly, but I feel like this is still difficult for me to understand. I'm stuck at the point where I'm supposed to make two VMs. I think I've made them as shown here in the capture.png

But how do I tell if I've set them up correctly? 

Capture.PNG

I noticed on your first step, you show the two VM settings. The one on the left (I'm assuming it's the second gen VM)  you have the SCSI Controller highlighted, showing the Hard Drive. On the right you have the first gen VM, showing the IDE Controller 1 Hard Drive. I noticed that you set the IDE controller to 1, and put the location to 0. When I try to do this, I get this image. Please see the FML.PNG below to see what I've done, and what I need to do next. 

FML.PNG

I may have failed to have Hyper-V Manager to pass-through my USB. Do I need to use diskpart to clean my USB disk, then select the location of the virtual hard disk to be on it? 

 

I'm quite determined, so as long as you're willing, I'll be fastidious to follow every instruction you give.

Edited by WIRM.KJones
7 minutes ago, WIRM.KJones said:

I noticed on your first step, you show the two VM settings. The one on the left (I'm assuming it's the second gen VM)  you have the SCSI Controller highlighted, showing the Hard Drive. On the right you have the first gen VM, showing the IDE Controller 1 Hard Drive. I noticed that you set the IDE controller to 1, and put the location to 0. When I try to do this, I get this image. Please see the FML.PNG below to see what I've done, and what I need to do next. 

FML.PNG

I'm quite determined, so as long as you're willing, I'll be fastidious to follow every instruction you give.

In your case if you are just wanting to create one windows to go drive you can passthrough the hard drive you want to use for windows to go.

 

To do this go to disk management and right click on your USB storage then hit "offline"

 

When you do this go back into the settings for both virtual machines and select the drive from the list highlighted below.

 

HDD.thumb.png.7b2be3a89ce430e8b9f42f8ecf32909e.png

 

Once that's done start VM1 and it will boot from the windows iso.

 

From there you can use the commands in the first post after pressing shift + f10 to open the command prompt on the Windows CD.

Now I'm on your step which states:

"At the install screen press shift + f10 to open command prompt and run notepad to get a GUI file explorer window when you select file > open

What am I supposed to do with this notepad?

I'm now here:

 

I'mSoSorryIKeepGettingStuck.PNG

I didn't know if I should have done this or not, but your instructions didn't say what to do with the notepad, so I closed notpad and continued with your next step. I cleaned the drive, converted it to MBR, and created the fat32 partition and the ntfs partition. After that, I typed in your command:

"Dism /apply-image /imagefile:E:\sources\install.wim /index:1 /ApplyDir:W:\"

When I did this I got this error message:

 

OopsIDidItAgain.PNG

Once again, thank you for all of your help! What would you recommend I do now? 

1 hour ago, WIRM.KJones said:

I didn't know if I should have done this or not, but your instructions didn't say what to do with the notepad, so I closed notpad and continued with your next step. I cleaned the drive, converted it to MBR, and created the fat32 partition and the ntfs partition. After that, I typed in your command:

"Dism /apply-image /imagefile:E:\sources\install.wim /index:1 /ApplyDir:W:\"

When I did this I got this error message:

 

OopsIDidItAgain.PNG

Once again, thank you for all of your help! What would you recommend I do now? 

You are nearly there, The error is stating that it cant find the install image if you open notepad from the command prompt and then hit file > open you will be able to find the drive letter the DVD drive has and then replace e:\sources\install.wim with whatever drive letter your vm has assigned for the DVD drive.

16 minutes ago, TPreston said:

You are nearly there, The error is stating that it cant find the install image if you open notepad from the command prompt and then hit file > open you will be able to find the drive letter the DVD drive has and then replace e:\sources\install.wim with whatever drive letter your vm has assigned for the DVD drive.

Oh I get it, you are just using the explorer in notepad to find the drive letters. I FEEL LIKE I'M SO CLOSE, THANK Y0U!

 

Okay, so my iso file letter is the same as your file letter "E:" but for some reason my Windows To Go ntfs disk became D: instead of W:

So I put in the command 

"Dism /apply-image /imagefile:E:\sources\install.wim /index:1 /ApplyDir:D:\"

and I got this error:

"The system cannot find the file specified.

The DISM log file can be found at X:\windows\Logs\DISM\dism.log"

SoClose.PNG

Yeah its

1 hour ago, WIRM.KJones said:

Oh I get it, you are just using the explorer in notepad to find the drive letters. I FEEL LIKE I'M SO CLOSE, THANK Y0U!

 

Okay, so my iso file letter is the same as your file letter "E:" but for some reason my Windows To Go ntfs disk became D: instead of W:

So I put in the command 

"Dism /apply-image /imagefile:E:\sources\install.wim /index:1 /ApplyDir:D:\"

and I got this error:

"The system cannot find the file specified.

The DISM log file can be found at X:\windows\Logs\DISM\dism.log"

SoClose.PNG

Yeah its not working because the iso you used contains esd files not an install.wim once you get an ISO mounted with a normal windows iso the command will work and then you just have the BCDBoot command to copy the boot files and you are done

Oh I see, okay. I am trying to install Windows 10 Pro. I downloaded this ISO using the MediaCreationTool, which I downloaded from Microsoft's website here:

https://www.microsoft.com/en-us/software-download/windows10

Do you know where I can get a Windows 10 Pro ISO that contains an install.wim instead of esd files?

Maybe something is wrong with my ISO. I'll try downloading Windows 10 again, using the MediaCreationTool, and see if I get the same error. 

It looks like the media creation tool will take some time though... so if you can think of anything I can try in the meantime, please let me know.

 

The MediaCreationTool just finished downloading a second ISO of Windows 10, it looks like it's still a esd file... oh fart... I'll see if I can scour the internet for an ISO of windows 10 Pro that has the install.wim instead of esd files, but I'm always a little skeptical on downloading operating systems other than from the official source. 

Edited by WIRM.KJones
1 hour ago, WIRM.KJones said:

So if I am correct, isn't an esd-ISO a form of all of the different Windows 10 systems (eg. Pro, Home, Education, single language, etc.) Is there a way I can extract just the Windows 10 Pro ISO from the esd ISO?

I don't know I used the MSDN isos try the media creation tool

MSDN ISO? Is there a website I can snag that from?

I stooped way low (in fact, I feel all dirty inside...) I downloaded a torrent from thepiratebay.

Here is the website here:

https://thepiratebay.org/torrent/12176822/Microsoft_Windows_10_Home_and_Pro_x64_Clean_ISO

I loaded this ISO into VM1, and typed in the command... it looks like it is working... is that a good sign? I hate using torrents...

IFeelDirty...PNG

Okay, so I took the risk and went ahead with the rest of the guide. It looks like it worked completely. Before I shut down my computer, and boot up from this USB device, do I need to turn it online using disk management? 

 

You my good sir, are eminent in my eyes! Thank you so much for all of your help. Hopefully I wasn't too much of an anathema for you.

Edited by WIRM.KJones

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Posts

    • 2 was a fun game but felt a bit shallow, like not enough there. I hope this expansion fixes that.
    • I haven't paid for windows since windows 8. So I guess I would be happy to pay for a new version if it meant seeing fewer adverts (none) or product pushes. But that applies to _any_ service or OS.
    • Save 35% on Sony's SS-CS5M2 3-way high-res bookshelf speakers by Taras Buria Sony is currently offering a big discount on its SS-CS5M2 bookshelf speaker, saving you 35% on a set of high-quality audio equipment. The SS-CS5M2 is a passive 3-way bookshelf speaker with a 5.12-inch woofer, a 25 mm soft-dome tweeter, and a 19 mm super tweeter. This design allows different drivers to handle different parts of the sound spectrum for a clearer, more detailed audio when watching movies or listening to music. The compact cabinet size allows you to place these speakers on shelves, desks, or stands, making them a practical choice for apartments, bedrooms, and small living rooms. Despite its compact size, the SS-CS5M2 delivers up to 100 W of power. Note that since the speakers are passive, you will need an amplifier to drive them. However, if you do, you can use them for high-resolution music, thanks to a claimed frequency response of 53 Hz - 50 kHz. It is able to extend so far high in the spectrum as a result of those super tweeters. While they will work with most amplifiers and AV receivers, Sony says this pair is a perfect match for its AV receivers, such as STRDH190, 590, 790, or 1000. Sony CS Bookshelf Speakers SS-CS5M2 3-Way 3-Driver Hi-res - $178 | 36% off on Amazon US This Amazon deal is US-specific and not available in other regions unless specified. This is a first-party seller link (at the time of article publishing); ensure that you also purchase from a first-party seller link only. If you don't like it or want to look at more options, check out the previous deals that we have covered, OR you can also visit Amazon US deals page. Get Prime (SNAP), Prime Video, Audible Plus or Kindle / Music Unlimited. Free for 30 days. As an Amazon Associate, we earn from qualifying purchases.
    • So they somehow expect Apple to easily make it so that if I install say DeepSeek that DS can then handle all the tasks that Siri would be doing while integrated in the OS? That sounds like just rediculous.
  • Recent Achievements

    • Rookie
      lamborghiniv10 went up a rank
      Rookie
    • One Month Later
      pinnclepd earned a badge
      One Month Later
    • First Post
      X-No-file earned a badge
      First Post
    • One Month Later
      johnjacobb40 earned a badge
      One Month Later
    • One Year In
      Primer1st earned a badge
      One Year In
  • Popular Contributors

    1. 1
      +primortal
      510
    2. 2
      PsYcHoKiLLa
      214
    3. 3
      +Edouard
      145
    4. 4
      Steven P.
      88
    5. 5
      ATLien_0
      83
  • Tell a friend

    Love Neowin? Tell a friend!