As a matter of fact, Microsoft doesn't allow to install windows on USB external devices. If you try to install Windows on external disk drive, you'll get this error:
Note: In this tutorial, I'll teach you how to install Windows on UEFI/GPT-based hard drive partition because almost every PC and MACBOOK run on it. BIOS/MBR-based hard drive partition has become obsolete.
cd X:\Windows\System32
dism /Apply-Image /ImageFile:R:\RecoveryImage\install.wim /Index:1 /ApplyDir:W:\
md T:\Recovery\WindowsRE
copy W:\Windows\System32\Recovery\winre.wim T:\Recovery\WindowsRE\winre.wim
bcdboot W:\Windows /s S: /f UEFI
W:\Windows\System32\reagentc /setosimage /path R:\RecoverImage /target W:\Windows /index 1
W:\Windows\System32\reagentc /setreimage /path T:\Recovery\WindowsRE /target W:\Windows
That's it! Exit the command prompt and close the Windows installation. Reboot and make sure external hard disk is your first priority on any Windows PC. If on Mac, reboot and keep pressing option/alt key until you get Boot Menu, select the EFI Boot and continue. It will reboot again so make sure to press option/alt key again as soon as the system starts and do the same.
And then after some more minutes you will be greeted to create your account!
That's all for today! If you stuck at any point, feel free to comment below!
Windows cannot be installed to this disk. Setup does not support configuration of or installation to disks connected through a USB or IEEE 1394 port.But you can install Windows by creating and configuring custom UEFI/GPT-based partition scheme.
Note: In this tutorial, I'll teach you how to install Windows on UEFI/GPT-based hard drive partition because almost every PC and MACBOOK run on it. BIOS/MBR-based hard drive partition has become obsolete.
Configuring Disk Partitions using Bootable Windows 10 USB
You have to create a Windows RE Tools partition, a system partition, an MSR partition, a Windows partition, and a recovery image partition. The following diagram shows this configuration:
After creating the partitions, you can apply the Windows image on the newly created partitions.
- Create a windows 10 USB bootable disk and boot from it.
- Once you're in the Setup program, select your language, time and currency format and input method, and click Next. Click the Install Now button. Enter/Skip your Windows key if prompted, and read and accept the software licence. In the next screen, press "SHIFT+F10" to open command prompt. Also connect your external hard disk.
- Now type diskpart and create the partition using the following script below:
list disk
select disk x (where x your disk number 0,1,2,3,... and so on)
clean (This will format the whole disk)
convert gpt
create partition primary size=350
format quick fs=ntfs label="Windows RE Tools"
assign letter="T"
set id="de94bba4-06d1-4d40-a16a-bfd50179d6ac"
gpt attributes=0x8000000000000001
create partition efi size=100
** NOTE: For Advanced Format 4Kn drives, change this value to size = 260 **
format quick fs=fat32 label="System"
assign letter="S"
create partition msr size=128
create partition primary size=256000
** NOTE: I've given 250GB Disk space to the drive where windows will be installed, change this value according to your disk size **
format quick fs=ntfs label="Windows"
assign letter="W"
create partition primary size=4096
format quick fs=ntfs label="Recovery Image"
assign letter="R"
set id="de94bba4-06d1-4d40-a16a-bfd50179d6ac"
gpt attributes=0x8000000000000001
**NOTE: I've a 500GB External hard disk and partitioned it accordingly. After this I get an unallocated disk space roughly say 245 GB which I can create a partition here using "create partition primary" or later after Windows installation using Disk Management. **
list volume
exit
select disk x (where x your disk number 0,1,2,3,... and so on)
clean (This will format the whole disk)
convert gpt
create partition primary size=350
format quick fs=ntfs label="Windows RE Tools"
assign letter="T"
set id="de94bba4-06d1-4d40-a16a-bfd50179d6ac"
gpt attributes=0x8000000000000001
create partition efi size=100
** NOTE: For Advanced Format 4Kn drives, change this value to size = 260 **
format quick fs=fat32 label="System"
assign letter="S"
create partition msr size=128
create partition primary size=256000
** NOTE: I've given 250GB Disk space to the drive where windows will be installed, change this value according to your disk size **
format quick fs=ntfs label="Windows"
assign letter="W"
create partition primary size=4096
format quick fs=ntfs label="Recovery Image"
assign letter="R"
set id="de94bba4-06d1-4d40-a16a-bfd50179d6ac"
gpt attributes=0x8000000000000001
**NOTE: I've a 500GB External hard disk and partitioned it accordingly. After this I get an unallocated disk space roughly say 245 GB which I can create a partition here using "create partition primary" or later after Windows installation using Disk Management. **
list volume
exit
Applying Windows, System, and Recovery Partitions by using Deployment Image Servicing and Management(DISM) Tool
Hope you didn't close the command prompt, if yes then again press SHIFT+F10 to open it.
Type C: and press enter.
Type Dir to check if it's your Windows 10 bootable pendrive. If not, use diskpart to verify your pendrive volume letter. list volume command in the above script shows the drive letter of your pendrive.
Now, type the following command in sequence:
md R:\RecoveryImage
copy C:\sources\install.wim R:\RecoveryImage\install.wim
cd X:\Windows\System32
dism /Apply-Image /ImageFile:R:\RecoveryImage\install.wim /Index:1 /ApplyDir:W:\
md T:\Recovery\WindowsRE
copy W:\Windows\System32\Recovery\winre.wim T:\Recovery\WindowsRE\winre.wim
bcdboot W:\Windows /s S: /f UEFI
W:\Windows\System32\reagentc /setosimage /path R:\RecoverImage /target W:\Windows /index 1
W:\Windows\System32\reagentc /setreimage /path T:\Recovery\WindowsRE /target W:\Windows
That's it! Exit the command prompt and close the Windows installation. Reboot and make sure external hard disk is your first priority on any Windows PC. If on Mac, reboot and keep pressing option/alt key until you get Boot Menu, select the EFI Boot and continue. It will reboot again so make sure to press option/alt key again as soon as the system starts and do the same.
And then after some more minutes you will be greeted to create your account!
Use BootCamp on Macintosh OS X to download drivers for Windows 10 which will be approximately 1.5 GB. Standalone/Offline driver download is not available as of now.
Boot Camp Assistant |
That's all for today! If you stuck at any point, feel free to comment below!
I can't find the file "install.win" in sources but I find install.ESD in the CD of windows 10
ReplyDeleteYou have to convert it from .ESD to .WIM. google how to do it.
Deleteso I have done everything you told us to do, and right now my laptop getting ready.
DeleteAND.......................... IT WORKS!!!!!!!
DeleteI CAN'T THANK YOU ENOUGH!!
Any help at all great people I am on the dism.exe apply image I'm typing it in exactly as I see it and it says the parameters are incorrect can anyone please help
DeleteWorked for me. I had to extract the install.wim file and put it on a separate external drive because the windows installer actually HIDES the install.wim file from its boot. I don't remember why exactly but I also had to use Windows 10 version 1803. I think its because the latest Windows 10 installer (1809) doesn't have a install.wim file at all.
ReplyDeleteThere is also a typo: As of 20190326, you misspelled the "RecoveryImage" folder in the 2nd to last command line in the last black border box.
Overall, extremely useful. Thank you for your help.
Wanted also to mention that my "winre.wim" file was 367,240,179 bytes which meant it wouldn't fit on a formatted size of 350MB.. so I made the T partition 368MB instead to have it fit.
ReplyDeletePerfect Steps. I am so grateful. It worked like charms for both Normal PCs and Windows on Mac.
ReplyDeleteGod bless you.
When i get to "copy C:\sources\install.wim R:\RecoveryImage\install.wim" it tells me that "the volume does not contain a recognised file system. Please make sure that all the required file system drivers are loaded and that the volume is not corrupted." Help please.
ReplyDeleteWooow it worked! I had to change the partition sizes but amazing I still can't believe it
ReplyDeletewhen i get to “ copy C:\sources\install.wim R:\RecoveryImage\install.wim” it says “ the system cannot find the path specified”. help?
ReplyDeletethe C: is just an example, make sure to put the correct letter from the list volume command
Deletemake sure you drill down into the /x64/sources or x86/sources before copying install.wim
Deletethis will depend on whether your cpu supports x64 (dual core) or 32 bit (x86)
if you type "dir" you should see a list that includes these directories
then tyep cd X:\x64\sources
then type dir again and you should be able to see the install.wim
then simply type 'copy install.wim R:\RecoveryImage\install.wim'
Big hug for you bro, worked like a Charm :*)
ReplyDeleteNotes:
1. install.esd works fine by itself, no need to convert it to wim
2. Also needed to extend T: size to fit winre.wim
3. Typo in path of second last command, its supposed to be RecoveryImage not RecoverImage ;)
Im having error "REAGENTC.EXE: The index of the recovery image (WIM) file must be specified."
ReplyDeleteWhen doing /setosimage. Any idea?
When I type in D:\sources\install.wim R:\RecoveryImage\install.wim
ReplyDeleteIt says there is not enough space.
How do I fix it??
We have to create the above partition in our external hard drive Or in laptop hardrive
ReplyDeleteI get an error during dism it stops at 80% error:433
ReplyDeleteA device which does not exist was specified. Any ideas?
Error 87
ReplyDeleteThe apply-image/imagefile option is unknown.
Please help..
/apply-image Is a command. /Imagefile is another command. Just insert a space !!!
DeleteMate I got the same problem even with the space, is there anything else I am missing?
DeleteHow you resolved it please help
DeleteCan anyone help me get past the "Reagent.exe is not compatible with the version of Windows you're running" message? I'm installing 64-bit Win 10 on a USB hard drive and currently have no operating system so finding/copying/moving files has to be done in the command prompt. I have just enough tech knowledge to be feared by tech experts far and wide, so any assistance would be greatly appreciated.
ReplyDeleteHow do I know whether mine is an Advanced Format 4Kn drive?
ReplyDeleteOn the line "W:\Windows\System32\reagentc /setosimage /path R:\RecoverImage /target W:\Windows /index 1" there's a typo, and needs to read "W:\Windows\System32\reagentc /setosimage /path R:\RecoveryImage /target W:\Windows /index 1
ReplyDeleteVery minor; but, wanted to let you know.
Basically just missing the 'y' in Recovery
DeleteAlso, since Windows 10 is so big these days, I recommend bumping up the file sizes.
DeletePlease am using the latest win 10 pro how do i get install.wim
ReplyDeletePlease help I really need this help
Great! I just installed windows 11 on an iMac 2017 external ssd
ReplyDeleteT must be 500 and R 4800, maybe little less
It even skipped the hardware limitations block
Only glitch is, if the external SSD is connected, always boots from it, even after selecting an other partition with Option key
DeleteThis comment has been removed by the author.
ReplyDeleteHow can I add Windows 11 as well side by side with the same way on the external hard disk? Thanks in advance
ReplyDeleteError: 87
ReplyDeleteThe apply-image/imagefile option is unkown,
For more information,refer to the help by running DISM.exe/?.
The DISM log file can be found at X:\windows\logs\DISM\dism.log
Please help
I had a FAT32 formatted Windows bootable drive and my install.wim was split into install.swm and install2.swm:
ReplyDeleteHad to adjust the commands for file copying and image application according to that:
copy C:\sources\install.wim R:\RecoveryImage\install.wim
copy C:\sources\install2.wim R:\RecoveryImage\install2.wim
.
.
.
dism /Apply-Image /ImageFile:R:\RecoveryImage\install.swm /SWMFile:R:\RecoveryImage\install*.swm /Index:1 /ApplyDir:W:\
Also needed to adjust T: and R:'s sizes.
Otherwise I can say that it is crucial to follow step 2 exactly (fucked up once because of this). My further installation experience: I hadn't entered a license key and after rebooting I was stuck on "Just a moment..." for quite long before it rebooted again and got me into repair mode, which works without internet connection gladly.
In the end it worked! Yay! Kisses to you!
As you can read before, I installed in augoust, but shortly later the boot porcess broke, and it was impossible to repair without formatting everytihng!
ReplyDeleteThen I doscovered the On the go installation of Rufus. It's really stable and solid, but can only be installed on a USB key.
I did it then copied on SSD with clonezilla.
You're not limited to one PC, you could go on the go to other ones, but the autmatic install of new drivers may break the install, so I use the good one of the 2 to clone into the bad
Higly recommended
When I type copy E:\sources\install.esd I get an error saying “there is not enough space on the disk. 0 files copied”
ReplyDeleteWorks great. Only problem was the T partition needs to be bigger. I set mine to 370 and still was not enough. Also no need to convert install.esd to .with.
ReplyDeleteThank you, man!! It worked like a charm. For disk, Just do install.esd when you don’t find the file, especially for latest windows!
ReplyDeleteWhen starting after the process is done a got a error says "The computer restarted unexpectedly or encountered an unexpected error.Windows installation cannot proceed ..
DeleteWhen creation the partions a had to resize :T a :R because they were to small for voting all files, what could be the problem I'm using the lastest Windows 10 iso from Microsoft page.thankyou
When starting after the process is done a got a error says "The computer restarted unexpectedly or encountered an unexpected error.Windows installation cannot proceed ..
ReplyDeleteWhen creation the partions a had to resize :T a :R because they were to small for voting all files, what could be the problem I'm using the lastest Windows 10 iso from Microsoft page.thankyou
This happen when I restart the computer to complete the installation,also I had selected EFI Boot
DeleteNevermind I had to download an old win 10 iso in order to successfully install..
DeleteThanks a lot you rock!! Now I have win 10 on my external HDD
when I do the first dism apply-image command it says unspecified error: 0x80004005
ReplyDeleteCan't boot from the usb SSD drive after completing the process sadly. And when booting from windows installation usb drive same message appears (cannot be installed on usb or IEEE1394 port)
ReplyDeleteDid you find another way?
Deletemd R:\RecoveryImage
ReplyDeletecopy C:\sources\install.wim R:\RecoveryImage\install.wim
cd X:\Windows\System32
What is this last line? My flash drive is d not c if that helps
This post is obsolete!
ReplyDeletejust use Rufus, with proper setting it can install Win11 also on an external SSD.
I did on a Mac and you should use MBR instaed of UEFI
Why don't you post a video or a neat write up on this?
DeleteI am trying to follow these instructions and I am getting error "The operation is not supported on removable media" on the format quick fs=fat32 step. I think I should try Windows to go in order for this to work.
ReplyDeleteAlso, I realized that my SD card is not recognized without drivers. So in Windows installer I have to browse and load my SD card reader driver before it becomes visible. And this makes me think, even if I succeed with the installation itself, the boot process will fail, because I can't load driver before Windows boot starts, but the card is not visible before the driver loads. Any ideas?
You did a fantastic job sharing this important information. We should always keep sharing this kind of information because about download microsoft office for windows it is significant and meaningful for us to learn more.
ReplyDeleteThanks it worked!!!! But windows can't find any drivers any idea why or how I can fix it?
ReplyDelete