Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Universal MediaCreationTool wrapper for all MCT Windows 10 versions from 1507 to 21H1 with business (Enterprise) edition support

We did it! We broke gist.github.com ;) So head over to the new home! Thank you all!
2021.10.20: https://github.com/AveYo/MediaCreationTool.bat now open for interaction

  • new update introducing no 11 setup checks on boot in VirtualBox

Not just an Universal MediaCreationTool wrapper script with ingenious support for business editions,
Preview
A powerful yet simple windows 10 / 11 deployment automation tool as well!

configure via set vars, commandline parameters or rename script like iso 21H2 Pro MediaCreationTool.bat
recommended windows setup options with the least amount of issues on upgrades set via auto.cmd
awesome dialogs with keyboard focus to pick target version and preset action

Auto Setup with detected media without confirmation
- can troubleshoot upgrade failing by adding no_update to script name
Create ISO with detected media in C:\ESD folder without confirmation
- can override detected media by adding edition name / language / arch to script name
Create USB with detected media after confirmation
- can click Back and select ISO instead to save in a different path
custom presets above support 'oem' media customization, that can be disabled by adding no_oem to script name
- pickup $OEM$ folder (if it exists) with any post setup tweaks like $OEM$\$$\Setup\Scripts\setupcomplete.cmd
- write sources\PID.txt file to preselect edition at media boot or setup within windows (if configured)
- write auto.cmd file to re-run auto setup on demand, from media (includes Skip TPM if sources are 11)
- write winpeshl.ini file in boot.wim to Skip TPM Check on media boot (if sources are 11)
Select in MCT with manual confirmation for everything in MCT GUI
- no 'oem' media customization, script passes products.xml configuration and quits without touching media

Skip TPM Check on Dynamic Update v1 (wmi-based) or v2 (ifeo-based) standalone toggle scripts in MCT\ dir
- system-wide, unblocks insider previews on windows update, or running setup.exe manually while online
- when using created media on another pc for the first time, can launch auto.cmd from media once to enable

discuss on MDL

2018.10.10: reinstated 1809 [RS5]! using native xml patching for products.xml; fixed syntax bug with exit/b
2018.10.12: added data loss warning for RS5
2018.11.13: RS5 is officially back! + greatly improved choices dialog - feel free to use the small snippet in your own scripts
2019.05.22: 1903 [19H1]
2019.07.11: 1903 __release_svc_refresh__ and enable DynamicUpdate by default to grab latest CU
2019.09.29: UPDATED 19H1 build 18362.356 ; RS5 build 17763.379 and show build number
            added LATEST MCT choice to dinamically download the current version (all others have hard-coded links)
2019.11.16: 19H2 18363.418 as default choice (updated hard-coded links)
2020.02.29: 19H2 18363.592
2020.05.28: 2004 19041.264 first release
2020.10.29: 20H2 and aniversary script refactoring to support all MCT versions from 1507 to 20H2!!!
2020.10.30: hotfix utf-8, enterprise on 1909+
2020.11.01: fix remove unsupported options in older versions code breaking when path has spaces.. pff
2020.11.14: generate latest links for 1909,2004; all xml editing now in one go; resolved known cannot run script issues
2020.11.15: one-time clear of cached MCT, as script generates proper 1.0 catalog for 1507,1511,1703 since last update
            fixed compatibility with naked windows 7 powershell 2.0 / IPv6 / optional import $OEM$ / 1803+ business typo
            updated executables links for 1903 and 2004
2020.11.17: parse first commandline parameter as version, example: MediaCreationTool.bat 1909
2020.12.01: attempt to fix reported issues with 1703; no other changes (skipping 19042.630 leaked esd because it is broken)
2020.12.11: 20H2 19042.631; fixed pesky 1703 decryption bug on dual x86 + x64; improved cleanup; label includes version
2021.03.20: pre-release 21H1; optional auto upgrade or create media presets importing $OEM$ folder and key as PID.txt
2021.05.23: 21H1 release; enhanced script name args parsing, upgrade from embedded, auto.cmd / PID.txt / $OEM$ import
2021.06.06: create iso directly; enhanced dialogs; args from script name or commandline; refactoring is complete!
2021.08.04: done fiddling
2021.09.03: 21H2, both 10 and 11 [unreleased]
2021.09.25: Windows 11
            with Skip TPM Check on media boot as well as on dynamic update (standalone toggle script available)
            final touches for improved script reliability; enhanced auto upgrade preset; win 7 powershell 2.0 compatible
2021.09.30: fix Auto Setup preset not launching.. automatically
2021.10.04: fix for long standing tr localization quirks; Skip TPM Check v2 (ifeo-based instead of wmi)
2021.10.05: 11 22000.194 Release (rofl W11 MCT has limited capabilities, so still using 21H1 MCT because it works fine)
2021.10.09: outstanding refactoring around Windows 11 MCT; minimize while waiting MCT; unified 7 - 11 appearence
            We broke gist.github.com ;) Script has a new home now: https://github.com/AveYo/MediaCreationTool.bat 

use download ZIP button or pastebin link to get the script, as saving the Raw file breaks line endings

* text=auto
* eol=crlf
@vancetech72

This comment has been minimized.

Copy link

@vancetech72 vancetech72 commented May 24, 2019

If I click "Upgrade this PC", will it still install the version I picked?

@karlo2105

This comment has been minimized.

Copy link

@karlo2105 karlo2105 commented Jun 22, 2019

Is Windows Enterprise LTSB/LTSC version available with this tool ? Do you get .iso or .img ?

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Jun 22, 2019

it will upgrade to the picked version (rather late reply as I've missed the notification)
no LongTermService editions available as Microsoft does not provide them publicly
mct can directly upgrade a pc, write setup files to an usb drive, or generate an iso

@harvestry-of-ghosts

This comment has been minimized.

Copy link

@harvestry-of-ghosts harvestry-of-ghosts commented Jul 5, 2019

After grabbing v1803 I notice that it is build 10.0.17134.112. There were 29 additional public release builds of v1803 released AFTER that one. Is there any way you make the script grab the last officially released ISO for v1803? The last build was 10.0.17134.860, released on June 26, 2019. Don't they always put out a new MCT whenever there is a new build released? I would at least think there would be a newer one than 29 builds behind the final one of v1803.

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Jul 11, 2019

They only do that for the current release, and very rarely for older ones
that's why I've made this script in the first place: because old MCT versions became unusable!

And those are not at all public release builds iso's, but subscription-only!

The script uses the latest public release builds ESD 's for MCT / windows update (except for 1809 since no updated link to products.cab is available while there are direct links to newer ESD's ripped from wu).
However I have adjusted the script to enable Dynamic Update by default,
MCT should download the latest cumulative update online and then integrate it, at least when doing an in-place upgrade. Should...

@Powershellder

This comment has been minimized.

Copy link

@Powershellder Powershellder commented Nov 4, 2019

Good day. I am wondering.. how do you find the links to the specific cab files, B and D.
For example .. if a new version came out, how would i be able to find out those 3 variables as even when specifically searching for it, i cannot seem to find any reference to those cab links at all, nor for the information found in B and D (aside from D being a date ofcourse)?

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Nov 4, 2019

Those are usually leaked before MCT releases.
Once a new mct build is available, run it, mine it's work folder for strings, then follow any new urls to the long link.
The second method is to run new windows feature update while monitoring for traffic.
You don't always get direct download links, it can be behind headers negotiation. curl and wget can help with that.
I'm only updating the script when a reliable direct url from microsoft is available.

@MIKEYCRYPTO

This comment has been minimized.

Copy link

@MIKEYCRYPTO MIKEYCRYPTO commented Nov 13, 2019

When using this string /Eula Accept /Retail /MediaEdition Pro /MediaArch x64 /MigChoice Upgrade /Auto Upgrade /MigrateDrivers all /DynamicUpdate Disable /ShowOOBE none

I get asked for a key (which i have purchased from a license distributor) and it halts the install.
Is there any way in the options to have it read a key or read a PID.txt file ?

Doing this across 248 machines in a domain.
Trying to make this as painless as possible.

@MIKEYCRYPTO

This comment has been minimized.

Copy link

@MIKEYCRYPTO MIKEYCRYPTO commented Nov 13, 2019

I think I figured out my own question.
Hope this will help with anyone that needs it
In the following section where the version is specified, you can create an entry for set "PKEY=
This will not prompt for a key while using the /Retail option.

:version-6
set "V=1903"
set "B=18362.356.190909-1636"
set "D=_20190912"
set "PKEY=XXXXX-XXXXX-XXXXX-XXXXX-XXXXX"
set "CAB=http://download.microsoft.com/download/4/e/4/4e491657-24c8-4b7d-a8c2-b7e4d28670db/products_20190912.cab"
set "MCT=http://software-download.microsoft.com/download/pr/MediaCreationTool1903.exe"
goto process

Now the only trouble that i have is that it halts when there is a video card compatibility issue. Clicking confirm will let the update run, but i would like to have it halt on no errors during deployment.

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Nov 14, 2019

First, auto upgrade is supposed to install the same edition, architecture and language, so /MediaEdition /MediaArch /MediaLangCode as well as /PKey should not be needed.
If you must override the existing edition, I guess it would be better to change the existing EditionID string in the registry (HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion) before running setup.

Second, try adding /Quiet

@bentman

This comment has been minimized.

Copy link

@bentman bentman commented Jun 18, 2020

Does anyone have a full list of command line switches for MediaCreationTool.exe?

I am specifically looking for things like:

:: Create ISO for another PC???
/Action CreateISO

:: Save ISO to Location ???
/Location D:\ISO%V%-%MediaEdition%-%MediaArch%-%MediaLangCode%.iso

End-Goal is to create a loop that creates multiple ISO's across several Languages.

Thanks!

@joss-c

This comment has been minimized.

Copy link

@joss-c joss-c commented Aug 4, 2020

When I run it the command prompt just says "No MCT_VERSION selected, exiting..."

Running as administrator made no difference. Any ideas?

@miguelcanilla

This comment has been minimized.

Copy link

@miguelcanilla miguelcanilla commented Aug 15, 2020

AveYo first of all thanks for create this batch file is awesome, I found a problem trying to create a windows 1909 Enterprise "There was a problem running this tool" and it close.

also you have plan for LTSC?

Thanks.

@pdjokic

This comment has been minimized.

Copy link

@pdjokic pdjokic commented Oct 30, 2020

Hi,

Does anyone know why i'm getting this error

image

image

This is displayed for every version on the list

@pdjokic

This comment has been minimized.

Copy link

@pdjokic pdjokic commented Oct 30, 2020

Hi,

Does anyone know why i'm getting this error

image

image

This is displayed for every version on the list

Found the culprit.
MediaCreationTool.bat should be expel from the extracted folder and it will run the selected version.

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Oct 30, 2020

Found the culprit.
MediaCreationTool.bat should be expel from the extracted folder and it will run the selected version.

That's a common issue with any zipped scripts if run directly via explorer zip-as-folder browsing.
Does not help that download gist as zip generates a ridiculous long random name that can fill max_path.
It's why I prefer pastebin links for .bat scripts as it downloads it directly keeping original extension.
(atm pending request to unblock after false-positive from pastebin's new lame "ai" auto-scan)
Anyway, glad you figured it out yourself!

@pdjokic

This comment has been minimized.

Copy link

@pdjokic pdjokic commented Oct 30, 2020

Found the culprit.
MediaCreationTool.bat should be expel from the extracted folder and it will run the selected version.

That's a common issue with any zipped scripts if run directly via explorer zip-as-folder browsing.
Does not help that download gist as zip generates a ridiculous long random name that can fill max_path.
It's why I prefer pastebin links for .bat scripts as it downloads it directly keeping original extension.
(atm pending request to unblock after false-positive from pastebin's new lame "ai" auto-scan)
Anyway, glad you figured it out yourself!

Hi AveYo,

I actually unzipped the files, and tried to run it from the unzipped folder. That's when i received the error. I moved only MediaCreationTool.bat outside of the unzipped location and that's when it worked.

@Tom999Hall

This comment has been minimized.

Copy link

@Tom999Hall Tom999Hall commented Nov 1, 2020

Doesn't work if the folder has a space in the name

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Nov 1, 2020

Doesn't work if the folder has a space in the name

guess that's a facepalm for me, since I thought those rookie mistakes were past me
this will not mater once I move it to powershell completely, but until then I will make a quick update to fix this
edit: it was because of %OPTIONS:...=% variable substitution usage, replaced that with findstr
btw this also fixes running the script directly from the gist zip 👍

@loco009

This comment has been minimized.

Copy link

@loco009 loco009 commented Nov 5, 2020

Me parece muy drastico.

@Emre028

This comment has been minimized.

Copy link

@Emre028 Emre028 commented Nov 10, 2020

1703 ISO Download not working please help me

@Emre028

This comment has been minimized.

Copy link

@Emre028 Emre028 commented Nov 10, 2020

@Emre028

1703 ISO Download not working please help me

Working fine here, 1703 Home/Pro/Edu x86 en-us, 1703 Home/Pro/Edu x64 en-us, 1703 vl Enterprise x64 en-us
Can you specify what are you doing and what are you expecting?

İs work vl enterprise x86_x64 aio
Not working home pro edu x86_x64
TR build İSO. my from Turkey, Giresun. Keşap

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Nov 11, 2020

@Emre028 thank you very much for reporting it!
It's my fault, I have switched to 1709 MCT for 1703 builds and only tested the download part being ok, then canceled before noticing it failing due to missing decryption stage I suppose. Will revert back to using 1607 MCT and that will fix this.
Sorry for the inconvenience!

@Emre028

This comment has been minimized.

Copy link

@Emre028 Emre028 commented Nov 11, 2020

@Emre028 thank you very much for reporting it!
It's my fault, I have switched to 1709 MCT for 1703 builds and only tested the download part being ok, then canceled before noticing it failing due to missing decryption stage I suppose. Will revert back to using 1607 MCT and that will fix this.
Sorry for the inconvenience!

You're welcome. Thank you for such a useful tool. Can you inform when the problem in 1703 is fixed?

@kikkoal

This comment has been minimized.

Copy link

@kikkoal kikkoal commented Nov 11, 2020

Unfortunately the file is not downloadable. help me?

@kikkoal

This comment has been minimized.

Copy link

@kikkoal kikkoal commented Nov 11, 2020

Thanks. Resolved

@MikeyD215

This comment has been minimized.

Copy link

@MikeyD215 MikeyD215 commented Nov 12, 2020

I just used this tool to create .iso files for updates 1909 and 2004. This tool worked like a charm. However, the 1909 .iso just created is exactly the same size (4,188,608 KB) as the .iso created last April, whereas the 2004 .iso just created is larger than the .iso I created just two months ago in September.

Is this tool grabbing the (October) refreshed version of 1909, v.18363.1139?

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Nov 14, 2020

@MikeyD215 at that time no. But now it does 🥇
@Emre028 1703 should be fixed now. Also exposed Cloud edition (Windows 10 S). Links for TR seem to download very slow..
Most reported cannot run script issues should be resolved now.
Unfortunately I cannot test very well downloading older versions atm due to internet issues.

@Emre028

This comment has been minimized.

Copy link

@Emre028 Emre028 commented Nov 14, 2020

@MikeyD215 at that time no. But now it does 🥇
@Emre028 1703 should be fixed now. Also exposed Cloud edition (Windows 10 S). Links for TR seem to download very slow..
Most reported cannot run script issues should be resolved now.
Unfortunately I cannot test very well downloading older versions atm due to internet issues.

1703 I'm trying now yes I have an extremely fast download speed of 35 mbps but it downloads at 10 mbps.

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Nov 14, 2020

I'm aware there might be issues with some links for the 1909 version, will try to solve once I get connectivity to microsoft back

@Emre028

This comment has been minimized.

Copy link

@Emre028 Emre028 commented Nov 14, 2020

I'm aware there might be issues with some links for the 1909 version, will try to solve once I get connectivity to microsoft back

1703 not working again :(

@snout-o

This comment has been minimized.

Copy link

@snout-o snout-o commented Nov 14, 2020

Hi @AveYo, thanks for making this handy tool.
Quick question: are you aware of any issues using your tool to download an old win10 iso and install via bootcamp to a MacBook Pro (late 2013)?
I tried pulling the oldest version iso using your tool but quickly ran in to issues at the win10 installation stage. I’ve documented the issues in this thread if you happen to have time to take a look.
My next plan is to try version 1607, but would be good to understand if I’m pssing in to the wind! Cheers

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Nov 14, 2020

It should not make any difference, but then again running Windows on Mac is not without quirks. Many quirks.
The media driver missing might be because you booted in uefi mode and the usb stick is made for mbr or viceversa.
If only for your peace of mind you should just download older windows 10 iso via techbench.

@snout-o

This comment has been minimized.

Copy link

@snout-o snout-o commented Nov 14, 2020

It should not make any difference, but then again running Windows on Mac is not without quirks. Many quirks.
The media driver missing might be because you booted in uefi mode and the usb stick is made for mbr or viceversa.
If only for your peace of mind you should just download older windows 10 iso via techbench.

Thanks for the link, although I’ve no idea if techbench can be trusted since it’s not a Microsoft service. Regarding efi & mbr, as far as I can tell from having tried this a dozen times that combination is how bootcamp always creates the bootable usb media. So I would think it should work, but of course this is newer software trying to work on older hardware, so who knows? If you know of an alternative combination for a bootable usb I’d be happy to hear it, but either way thanks for your help!

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Nov 15, 2020

@snut-o techbench just ask microsoft for a temporary 24h link to respective iso; if you check the link it's on microsoft's servers, 100% official (sort of how this script also provides official direct links to esd on microsoft's servers; I prefer esd's for the way smaller download size, and mct for the verification capability)

In other news, fixed most issues I could find that happened once I refactored the script. (@Emre028, 1703 TR works now for me).
Script code is now finalized, tested and should be considered stable.

@MikeyD215

This comment has been minimized.

Copy link

@MikeyD215 MikeyD215 commented Nov 15, 2020

Thanks for the repair. I used your tool to create a new iso for 1909 and this time it was the correct, refreshed build 1139, verified with DISM.

@Dezirdt-Uzurnaim

This comment has been minimized.

Copy link

@Dezirdt-Uzurnaim Dezirdt-Uzurnaim commented Nov 16, 2020

@AveYo This is amazing work! Thank you.
I do have a question for you or anyone that can assist; I'm wanting to explore this as a secondary option to get some remote workers upgraded to 1909. Is there a way I can get the batch to only display 1909? Or, even better, how could I input that option into the powershell command to run it for them? Thanks again. Cheers

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Nov 17, 2020

@Dezirdt-Uzurnaim sure, I had that in mind when I've put the choices at the very top.
set CHOICES= 1507, 1511, 1607, 1703, 1709, 1803, 1809, 1903 [19H1], 1909 [19H2], 2004 [20H1], 2009 [20H2]
to
set CHOICES= 1909 [19H2]
This will present a dialog with just 1909 and Cancel (so you can abort it without downloading anything).

Or

rem set/a MCT_VERSION=11
to
set/a MCT_VERSION=9
This will start downloading 1909 MCT immediately and then launch it.

I guess I could also add a command line argument so you could simply run MediaCreationTool.bat 1909 or whatever version.

@Emre028

This comment has been minimized.

Copy link

@Emre028 Emre028 commented Nov 18, 2020

@snut-o techbench just ask microsoft for a temporary 24h link to respective iso; if you check the link it's on microsoft's servers, 100% official (sort of how this script also provides official direct links to esd on microsoft's servers; I prefer esd's for the way smaller download size, and mct for the verification capability)

In other news, fixed most issues I could find that happened once I refactored the script. (@Emre028, 1703 TR works now for me).
Script code is now finalized, tested and should be considered stable.

https://i.hizliresim.com/iuD8pO.png
I tried all versions but the result is the same..

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Nov 20, 2020

@Emre028 I cannot confirm your issue. Retested couple times and it works.
Either your government or microsoft must be blocking you, maybe you should try using a VPN, or if you are already using one, change it.

As far as this script is concerned, I don't see an issue. Might be worth a try to start creating a 1607 and then cancel it after mediacreationtool start, go to MCT folder, rename MediaCreationTool1607.exe to MediaCreationTool1703.exe and then start creating your 1703 and see if you have more success that way.

These are the direct links for enterprise tr 1703: x64 and x86.
If you can download them via the internet browser, then you could use them with ESD-to-ISO if all else fails.

@Emre028

This comment has been minimized.

Copy link

@Emre028 Emre028 commented Nov 22, 2020

@Emre028 I cannot confirm your issue. Retested couple times and it works.
Either your government or microsoft must be blocking you, maybe you should try using a VPN, or if you are already using one, change it.

As far as this script is concerned, I don't see an issue. Might be worth a try to start creating a 1607 and then cancel it after mediacreationtool start, go to MCT folder, rename MediaCreationTool1607.exe to MediaCreationTool1703.exe and then start creating your 1703 and see if you have more success that way.

These are the direct links for enterprise tr 1703: x64 and x86.
If you can download them via the internet browser, then you could use them with ESD-to-ISO if all else fails.

I tried downloading without using vpn failed. Then I tried downloading with Vpn again failed. I wonder if there is a problem with the AIO version download. I did not try to download it separately with MCT. If there is no problem, I do not want to muddy your valuable work by saying there is a problem here. Best regards Emre028!

@Xeoping

This comment has been minimized.

Copy link

@Xeoping Xeoping commented Nov 30, 2020

Anybody else is getting stock at 31% when downloading 1909 (English American, Pro, 64bit)? I've tried 1809 which I was able to download at 100%.

@dakhama-mehdi

This comment has been minimized.

Copy link

@dakhama-mehdi dakhama-mehdi commented Nov 30, 2020

Hi good idea,
a want to add it or integre it with my tool Burn-and-Boot, to help people to create also a bootable media MBR or UEFI, From ESD or WMI, without use MCT, because MCT have the limit.
that is link for my free tool, it is a one of few compatible with SecureBoot
https://github.com/dakhama-mehdi/B-B-ISO
you can contact me by messagebox,
thanks,

@pfilippone

This comment has been minimized.

Copy link

@pfilippone pfilippone commented Dec 1, 2020

Do you have direct links to 1703 Home Pro EDU x86 & x64? The 1703 doesn't work from the Batch file.

@Xeoping

This comment has been minimized.

Copy link

@Xeoping Xeoping commented Dec 1, 2020

Do you have direct links to 1703 Home Pro EDU x86 & x64? The 1703 doesn't work from the Batch file.

I get an error code: 0x8007000D - 0x90002 during download for 1703 Home Pro EDU x64

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Dec 1, 2020

added some changes for 1703.
try again, both normal build and enterprise build (if enterprise build works, I could adjust all the other if still not working)
might also want to use cloudflare dns (1.1.1.1) instead of your isp dns
like I said before, I can't reproduce an issue, it works here in Europe without any changes, tested multiple languages, x64, x32, normal, enterprise etc

@Xeoping

This comment has been minimized.

Copy link

@Xeoping Xeoping commented Dec 2, 2020

So now, I can download 1909 English (United State) | Pro | x64. to 84% before the download get stalled. Changing my DNS didn't help...

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Dec 2, 2020

Can't do anything about that. If you just wait, it will resume eventually.
Again, this is not an issue with the script, but with your connection to microsoft servers

@pfilippone

This comment has been minimized.

Copy link

@pfilippone pfilippone commented Dec 3, 2020

Do you have direct links to 1703 Home Pro EDU x86 & x64? The 1703 doesn't work from the Batch file.

I get an error code: 0x8007000D - 0x90002 during download for 1703 Home Pro EDU x64

Yes I still get the same errors although 1703 Home Pro Edu x86 worked. x64 still does not work or the combined x86/x64.

@b9AcE

This comment has been minimized.

Copy link

@b9AcE b9AcE commented Dec 3, 2020

Seeing others had a problem, I decided to test downloading 1703 Home/Pro/Edu, English (U.S.) combined x86+x64 too and indeed, after the download and verification reached 100%, there was a "0x8007000D - 0x90002" error.
The test was run on a dedicated 100/100Mb/s fiber connection in Sweden with Google DNS through DNS-over-HTTPS, then again through a ProtonVPN connection exiting in NYC with the same results.
Something seems to be wrong.

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Dec 4, 2020

Thank you for your reports @b9AcE @pfilippone
I've been flipping stuff with every change now, quite possible I made it worse.
It would help me sort this out if you can provide your generated products.xml for 1703

@b9AcE

This comment has been minimized.

@mdonato9

This comment has been minimized.

Copy link

@mdonato9 mdonato9 commented Dec 5, 2020

I've tried renaming the name to "auto mediacreationtool.bat", tried removing the comment on line 26 and tried adding /quiet to the line 26 and I'm still getting prompted to accept the "Applicable Notices and License Terms" when the setup potion of the script runs. Is it possible for the script to run all the way through silently? Thanks for any help and this script is great!

@satyamisme

This comment has been minimized.

Copy link

@satyamisme satyamisme commented Dec 5, 2020

:: Uncomment to force Eula
set OPTIONS=%OPTIONS% /Eula Accept

@mdonato9

This comment has been minimized.

Copy link

@mdonato9 mdonato9 commented Dec 5, 2020

:: Uncomment to force Eula
set OPTIONS=%OPTIONS% /Eula Accept

i've uncommented line 26 which has that option in it and i'm still prompted during the setup portion

am i making the correct assumption that with this and even the /quiet option that this should run completely unattended the whole way through?

@satyamisme

This comment has been minimized.

Copy link

@satyamisme satyamisme commented Dec 5, 2020

:: uncomment to force a specific Edition, Architecture and Language - if enabled, all 3 should be used
set OPTIONS=%OPTIONS% /MediaEdition Enterprise /MediaArch x64 /MediaLangCode en-us

:: uncomment to force Auto Upgrade without user intervention - or just rename the script to "auto MediaCreationTool.bat"
set OPTIONS=%OPTIONS% /Eula Accept

:: uncomment to force Specific key to "auto MediaCreationTool.bat"
set "PKEY=XGVPP-NMH47-7TTHJ-W3FW7-8HV2C"

@ZenoNiQ

This comment has been minimized.

Copy link

@ZenoNiQ ZenoNiQ commented Dec 7, 2020

@AveYo Hi from dota2.dev btw. Can you tell me why if i dl by your .bat i have one size 4,34Gb,direct from the ms by this guide another one size 5,47Gb and by rufus another one 5,71Gb. I checked hash by Get-FileHash on ms and ms ISO original.

@ghost

This comment has been minimized.

Copy link

@ghost ghost commented Dec 9, 2020

Another user mentioned this issue and I did not see if they got a reply. When running the .bat as an admin, the cmd prompt pops up and the list of versions, but no matter which I click on, the cmd fails with error NO MCT_VERSION SELECTED . It then closes immediately. Any help would be hugely appreciated.

I did extract the file from the .zip and verified nothing should be blocking it.

EDIT: Ignore this. Apparently I just wasn't fast enough in clicking the version. Maybe consider increasing the timeout limit?

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Dec 11, 2020

@Emre028, @Xeoping, @pfilippone, @b9AcE - finally worked around the 1703 issue by reverting to the rtm products.xml - this affects consumer editions, while the added Enterprise and Cloud (S) editions are fine with the refreshed esd. I've kept assuming it's related to servers corrupting downloaded esd, but it turns out downloads are fine, hashes and sizes match, file names match - it's just a MCT internal decryption mismatch that happens more often when you create a x86 + x64 iso than when doing single architecture. Took a lot of time to figure it out 😞

@ZenoNiQ, MCT creates an iso with install.esd, a highly compressed format resulting in much smaller sizes than the ISOs provided as a direct download by microsoft. It's actually one of MCT's strong points. MCT also creates iso's with a different hash each time, but the result is perfectly safe - all individual files will match signatures.

@ghost, there is no timeout, on default windows settings the dialog can stays there for a day and will work when clicked.
What most likely happens is that an AV or something is killing the powershell process on your system shortly, so cmd gets no result.

@Aleexiius

This comment has been minimized.

Copy link

@Aleexiius Aleexiius commented Dec 13, 2020

Any time i try to use any type of mct older than 20h2 it says that there is a most recent version and i need it for continue. Is there something i can do for fix it?

@TTonsfeldt

This comment has been minimized.

Copy link

@TTonsfeldt TTonsfeldt commented Dec 16, 2020

Trying to use auto MediaCreationTool.bat to upgrade from windows 7 to windows 10 however it seems to ask to select image.

Where are all the options for the Auto Function?
comment line 17 and 20
uncomment Line 23 and 26
Set line 42 to MCT_Version 9

Trying to Install Windows 10 Pro

What other options need to be setup for this to function automatically?

Trying to use PDQ Deploy Software to Push out the Files and run the Batch file using just the batch file with no switches

@Kindaas

This comment has been minimized.

Copy link

@Kindaas Kindaas commented Dec 31, 2020

I've uncommented line 26, yet I am still prompted to accept the EULA. Any idea how to rectify this???

25 :: Uncomment to force Auto Upgrade - no user intervention needed
26 set OPTIONS=%OPTIONS% /Eula Accept /MigChoice Upgrade /Auto Upgrade /Action UpgradeNow

@anhtnt15

This comment has been minimized.

Copy link

@anhtnt15 anhtnt15 commented Jan 9, 2021

Hi Kindaas, is your problem solved? I have the same problem with get prompted to accept Applicable Notices and License Terms the second time, even though I used /Eula Accept

@Kindaas

This comment has been minimized.

Copy link

@Kindaas Kindaas commented Jan 9, 2021

No, I have not.
I've run it without any automation, and there seems to be two different times you have to accept the licensing. At this point, I am assuming there is another undocumented switch at play. If I find anything I will post it. I hope you will do the same

@anhtnt15

This comment has been minimized.

Copy link

@anhtnt15 anhtnt15 commented Jan 10, 2021

No, I have not.
I've run it without any automation, and there seems to be two different times you have to accept the licensing. At this point, I am assuming there is another undocumented switch at play. If I find anything I will post it. I hope you will do the same

Ok thank you and hope you find the solution soon

@lancer8860

This comment has been minimized.

Copy link

@lancer8860 lancer8860 commented Jan 13, 2021

DEAD TODAY,Must download the latest version MediaCreationTool

@dakhama-mehdi

This comment has been minimized.

Copy link

@dakhama-mehdi dakhama-mehdi commented Jan 13, 2021

Hi everyone, you can use this free opensource tool, that can keep you to download any version Win10 from Official Store, on fast time
https://github.com/dakhama-mehdi/CMC-ISO
select v2.0.1

@yorkshire-pudding

This comment has been minimized.

Copy link

@yorkshire-pudding yorkshire-pudding commented Jan 17, 2021

I need to download 1909 as Windows says 2004 is not ready for my PC and I want to do a reinstall of everything.
I tried to use this a couple of ways. First, using the GUI to select 1909, secondly, bypassing the GUI to go direct to 1909

I get this:

image

image

I've checked urls in browser and they work. I've deleted the MCT directory. I'm not sure what I need to do to unblock powershell or enable BITS serv.

Any advice please?

@Kindaas

This comment has been minimized.

Copy link

@Kindaas Kindaas commented Jan 17, 2021

@ yorkshire-pudding - My understanding is that you cannot upgrade 1809 and earlier directly to 2004 or 20H2 directly, although I have not tested this.

@yorkshire-pudding

This comment has been minimized.

Copy link

@yorkshire-pudding yorkshire-pudding commented Jan 17, 2021

@Kindaas - I am on 1909. I believe the reason I can't yet upgrade to 2004 is to do with a driver issue. However, all I want to do is download 1909 fresh so I can do a fresh install. The messages about not being able to upgrade to 2004 is in Windows Update, not in this tool, hence why I wasn't even trying to do 2004 - don't want to upgrade and then find that hardware doesn't work.

@nytram-md

This comment has been minimized.

Copy link

@nytram-md nytram-md commented Jan 18, 2021

Hi

We are on Enterprise at work and need to upgrade machines remotely and this tool looks great as we can send it out to machines but is there a way to stop the UAC prompt when the script is running as we wont have a tech person with the machine ?

Also, When it gets to the Ready to Install screen and default to keep personal files and apps, this defaults to wipe clean the machine.

What have I done wrong ?

Thanks in advance

Martyn

@nytram-md

This comment has been minimized.

Copy link

@nytram-md nytram-md commented Jan 21, 2021

Hi. Is anyone able to confirm the actual line for just upgrading Windows 10 Enterprise to latest version of this script for enterprise ? What ever I do, it stops at the ready to install and I dont want it to ?

Ive renamed the bat file to auto MediaCreationTool.bat and also commented and uncommented lines but all roads lead to the same point where I have to choose if I want to Install Windows Enterprise and keep personal files but I have to press Install.

Also, can /MediaLangCode en-us be changed to en-gb as we have english UK on all our mahcines ?

Should this not just upgrade without asking ?

Thanks again

Martyn

@EsherionM

This comment has been minimized.

Copy link

@EsherionM EsherionM commented Feb 8, 2021

@bentman here are all switches i found:
/1394debug /Action /ActionListFile /Advertisement /Auto /AzureHost /BitLocker /Boot /CancelId /ClientId /ClientId %s /Compact /CompactOS /Compat /ConfigFile /Console /CopyLogs /CopyLogs "%s" /CorrelationVector /DefaultApps /DiagnosticAnalysis /DiagnosticPrompt /Download /DownloadSizeInMB /Drive /DynamicUpdate /EnterpriseAttribution /Eula /ExpressPackage /Finalize /FlightBVT /FlightData /FlightData %s /ImageIndex /Install /InstallDrivers /InstallFOD /InstallFile /InstallLangPacks /InstallPrivates /LaunchSetup /LaunchSetupWithConfig /MCTUILanguage /Media /MediaArch /MediaEdition /MediaLangCode /MediaPath /MeteredNetwork /MigChoice /MigNEO /MigRollback /MigXmlPath /MigrateDrivers /NoAutoExit /NoReboot /Override /Package /PartnerID /PauseId /Pkey /PostOobe /PostRollback /PostRollbackContext /PreDownload /PreOobe /Priority /Prompt /Quiet /Recovery /ReflectDrivers /ReportId /ReportId %s /ResizeRecoveryPartition /Retail /RollbackSys /RollbackUser /RunRollbackScript /SMode /Selfhost /ShowOobe /SkipFinalize /SkipSummary /Success /Telemetry /Tempdrive /Unattend /Uninstall /Update /UpdateAndShutdown /UpdateMedia /WUCachedFileName /WaitForDebugger /WaitForDebugger switch detected. Please attach a debugger to continue... /Web /baudrate /busparams /debug /netdebug /optinsqm /performdu /pkd /preoobecmd /progressCLSID /tempdrive /unattend /usbdebug

There are more String in MediaCreationTool.
You can view that all with ProcessExplorer with Proberties->Strings on the Process.

@bentman

This comment has been minimized.

Copy link

@bentman bentman commented Feb 8, 2021

@EsherionM - Wow! Thanks for the tips from a different perspective... big help!

@Dezirdt-Uzurnaim

This comment has been minimized.

Copy link

@Dezirdt-Uzurnaim Dezirdt-Uzurnaim commented Feb 9, 2021

I need to download 1909 as Windows says 2004 is not ready for my PC and I want to do a reinstall of everything.
I tried to use this a couple of ways. First, using the GUI to select 1909, secondly, bypassing the GUI to go direct to 1909

I get this:

image

image

I've checked urls in browser and they work. I've deleted the MCT directory. I'm not sure what I need to do to unblock powershell or enable BITS serv.

Any advice please?

I had to comment out SET Choices when I used set/a for the MCT version.
Try that

@Dezirdt-Uzurnaim

This comment has been minimized.

Copy link

@Dezirdt-Uzurnaim Dezirdt-Uzurnaim commented Feb 9, 2021

@Dezirdt-Uzurnaim sure, I had that in mind when I've put the choices at the very top.
set CHOICES= 1507, 1511, 1607, 1703, 1709, 1803, 1809, 1903 [19H1], 1909 [19H2], 2004 [20H1], 2009 [20H2]
to
set CHOICES= 1909 [19H2]
This will present a dialog with just 1909 and Cancel (so you can abort it without downloading anything).

Or

rem set/a MCT_VERSION=11
to
set/a MCT_VERSION=9
This will start downloading 1909 MCT immediately and then launch it.

I guess I could also add a command line argument so you could simply run MediaCreationTool.bat 1909 or whatever version.

Ok, so I got this working. I've successfully tested 1909, 2004 and 2009.
However, if I run with the /Quiet argument, it fails. Which is fine, because I don't necessarily want this to run fully unattended.

The issue I'm having is when checking the command line that's being passed:
SetupHost::Initialize: CmdLine = [/Download /Web /Quiet /Selfhost "/Auto" "Upgrade" "/DynamicUpdate" "Disable" "/MigrateDrivers" "All" "/ResizeRecoveryPartition" "Disable" "/ShowOOBE" "None" "/Compat" "IgnoreWarning" "/Telemetry" "Disable" "/BitLocker" "AlwaysSuspend" "/CopyLogs" "\\apps01\install\!UpgradeLogs" "/DiagnosticPrompt" "Enable" ]

Why does it look like that?
The EULA shows for the user and the option to upgrade or create media options screen shows as well.
Is there a way to stop either or both of those? /AcceptEULA does not appear to work.

@Orngali63

This comment has been minimized.

Copy link

@Orngali63 Orngali63 commented Feb 12, 2021

В данное время пользуюсь:
Выпуск Windows 10 Pro
Версия 21H1
Дата установки ‎06.‎04.‎2021
Сборка ОС 19043.928
Взаимодействие Windows Feature Experience Pack 120.2212.551.0

image

Параметры 2021-04-15 09 09 00

@Kindaas

This comment has been minimized.

Copy link

@Kindaas Kindaas commented Feb 16, 2021

When I run this script without the /Eula accept switch, I get one EULA pop-up (with a scroll bar) very early in the process, and a second Eula pop-up (without a scroll bar) later, after the system check.

When I run the script WITH the /EULA Accept switch, I no longer get the EULA pop-up (with a scroll bar), but still the second Eula pop-up (without a scroll bar) later, after the system check.

Is, or has anyone else run into this? If so, can you tell me how you got around it???

@Powershellder

This comment has been minimized.

Copy link

@Powershellder Powershellder commented Feb 17, 2021

When I run this script without the /Eula accept switch, I get one EULA pop-up (with a scroll bar) very early in the process, and a second Eula pop-up (without a scroll bar) later, after the system check.

When I run the script WITH the /EULA Accept switch, I no longer get the EULA pop-up (with a scroll bar), but still the second Eula pop-up (without a scroll bar) later, after the system check.

Is, or has anyone else run into this? If so, can you tell me how you got around it???

Running against this to when going for the 20H2 version. When running the script automated it means that after a bit of activity I just see the modern setup host sitting idle without doing anything .. meaning its stuck on something.
And when running it manually with the parameters I did also notice that it couldnt get through the entire installation fully without any interaction.
Sadly havent found a way to fix that yet, hopefully someone else has more braincells that i'm lacking will be capable of fixing it ;D

@nytram-md

This comment has been minimized.

Copy link

@nytram-md nytram-md commented Feb 17, 2021

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Feb 17, 2021

it used to work with /quiet just fine before, but now stuff got changed at os level via "system readiness" updates
and there are more incompatible switches than before
keep in mind this was not meant as a unattended setup launcher, the auto thingy was just for extra bit of convenience
will see how to address the double eula

@TTonsfeldt

This comment has been minimized.

Copy link

@TTonsfeldt TTonsfeldt commented Feb 17, 2021

What is the best commands to automate this the best case scenario? Any ways to bypass the checks about drivers issues?

@Kindaas

This comment has been minimized.

Copy link

@Kindaas Kindaas commented Feb 24, 2021

It seems that the reason I cannot get past the second EULA is because the process re-starts the setup.exe without passing the switches applied to the 1st setup.exe.

@johnorotisimo

This comment has been minimized.

Copy link

@johnorotisimo johnorotisimo commented Feb 25, 2021

Neat tool! It is definitely helping me out. Tying to gen an older version of w10 Ent 1909 18363.418 for a Teams Rooms install. he tool worked great but I got the refreshed version of this release, 18363.1139. Is this controlled by MS? is there a way to get the .418 version?

Thanks,
John

@abnranger67

This comment has been minimized.

Copy link

@abnranger67 abnranger67 commented Mar 2, 2021

Not sure if anyone has been successful at getting the EULA to stop appearing because I still get it even with /quiet and the /accept EULA uncommented. Other than this minor issue, I love the tool. I have even edit it to do postoobe so it installs video drivers and other customizations like decrapify windows etc.

@Powershellder

This comment has been minimized.

Copy link

@Powershellder Powershellder commented Mar 2, 2021

Not sure if anyone has been successful at getting the EULA to stop appearing because I still get it even with /quiet and the /accept EULA uncommented. Other than this minor issue, I love the tool. I have even edit it to do postoobe so it installs video drivers and other customizations like decrapify windows etc.

Nope, nothing yet sadly.

For now ive resorted to using the Upgrade Assistant for silent install. The only downside there is that you cant choose whether it will reboot or not (It sadly always will) but at least it doesnt get stuck :P

@abnranger67

This comment has been minimized.

Copy link

@abnranger67 abnranger67 commented Mar 2, 2021

Ok, new glitch per se, even with OPTIONS=%OPTIONS% /MediaEdition Enterprise /MediaArch x64 /MediaLangCode en-us because I want the upgrade to end up as Enterprise, and set OPTIONS=%OPTIONS% /Eula Accept /MigChoice Upgrade /Auto Upgrade /Action UpgradeNow uncommented, "Read to install" and the recap to what you"ve chose to: dialog box. I would think that by uncommenting the option to upgrade to enterprise, that should avoid that window, especially since the machine is already Enterprise. I will add the pkey option and see if that gets rid of that.

@abnranger67

This comment has been minimized.

Copy link

@abnranger67 abnranger67 commented Mar 2, 2021

Ok, is it set OPTIONS=%OPTIONS% /pkey NPPR9-FWDCX-D2C8J-H872K-2YT43 or set pkey NPPR9-FWDCX-D2C8J-H872K-2YT43?

@abnranger67

This comment has been minimized.

Copy link

@abnranger67 abnranger67 commented Mar 2, 2021

Adding this set "pkey NPPR9-FWDCX-D2C8J-H872K-2YT43" did not get rid of the dialog box, but at least it did not bomb the process. However, I do not see it passed in the command line when I looked in task manager. I even tried passing to a setupconfig.ini file, but adding that option cause the process to only download the MCT, but not run the setuphost.

@abnranger67

This comment has been minimized.

Copy link

@abnranger67 abnranger67 commented Mar 3, 2021

@Dezirdt-Uzurnaim sure, I had that in mind when I've put the choices at the very top.
set CHOICES= 1507, 1511, 1607, 1703, 1709, 1803, 1809, 1903 [19H1], 1909 [19H2], 2004 [20H1], 2009 [20H2]
to
set CHOICES= 1909 [19H2]
This will present a dialog with just 1909 and Cancel (so you can abort it without downloading anything).
Or
rem set/a MCT_VERSION=11
to
set/a MCT_VERSION=9
This will start downloading 1909 MCT immediately and then launch it.
I guess I could also add a command line argument so you could simply run MediaCreationTool.bat 1909 or whatever version.

Ok, so I got this working. I've successfully tested 1909, 2004 and 2009.
However, if I run with the /Quiet argument, it fails. Which is fine, because I don't necessarily want this to run fully unattended.

The issue I'm having is when checking the command line that's being passed:
SetupHost::Initialize: CmdLine = [/Download /Web /Quiet /Selfhost "/Auto" "Upgrade" "/DynamicUpdate" "Disable" "/MigrateDrivers" "All" "/ResizeRecoveryPartition" "Disable" "/ShowOOBE" "None" "/Compat" "IgnoreWarning" "/Telemetry" "Disable" "/BitLocker" "AlwaysSuspend" "/CopyLogs" "\\apps01\install\!UpgradeLogs" "/DiagnosticPrompt" "Enable" ]

Why does it look like that?
The EULA shows for the user and the option to upgrade or create media options screen shows as well.
Is there a way to stop either or both of those? /AcceptEULA does not appear to work.

For some reason, my command line still shows telemetry enable. Not a big deal, cause it just means sending data back to MS. How did you bypass the Ready to install dialog, where it also gives you the option to change what to keep etc.?

@abnranger67

This comment has been minimized.

Copy link

@abnranger67 abnranger67 commented Mar 3, 2021

image

image

How do I get rid of this?
@nytram-md

This comment has been minimized.

Copy link

@nytram-md nytram-md commented Mar 3, 2021

@nytram-md

This comment has been minimized.

Copy link

@nytram-md nytram-md commented Mar 4, 2021

@abnranger67

This comment has been minimized.

Copy link

@abnranger67 abnranger67 commented Mar 4, 2021

Not sure why this is happening when I run it against win7 to win10. I assume that like before, the pkey option is not being passed. These are win7 Pro, and the Win10 are Enterprise, nonetheless, the pkey switch is not passing even when it is included in the command like set "pkey NPPR9-FWDCX-D2C8J-H872K-2YT43"

image

image

@Kindaas

This comment has been minimized.

Copy link

@Kindaas Kindaas commented Mar 4, 2021

The problem appears to be that the original setup.exe, with all of the selected switches, is restarting at some point in the process. And when it is restarted, no switches are applied.
I needed to get moving on my upgrades, so I am script robocopy to get the files to the PC, then executing the setup.exe with the switches. It is working perfectly.
The MCT was good while it lasted, but it appears we've been microshafted again.

@abnranger67

This comment has been minimized.

Copy link

@abnranger67 abnranger67 commented Mar 4, 2021

Yes, my normal process does as you mentioned, but sometimes the in-place upgrade fails for one reason or another, and when I use the MCT, it seems to fix the issues, hence my trying to leverage this tool. Thanks for the tip/insight

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Mar 20, 2021

Hello! I bring news. Beside the introduction of 21H1 MCT ;)

First, I have added create media preset(s) that when used, will send you right at the select usb or save iso dialog.
And when booting from the media, the pick edition dialog will be skipped.
The attempts I've seen in this thread were mostly failing because /Pkey option is only meant for retail bought keys, not for generic / hwid!
To overcome this limitation script simply generates a PID.txt with the key you provide and then adds it to the media sources folder.

Second, I have reworked the auto upgrade preset (actually more like reverted it to how it was intended initially).
The notable change is that the script now has to take the initiative and ask for admin rights itself.
That's so it can wait in the background for MCT to finish the first phase of creating upgrade media.
Once that's done, it will launch setupprep for the second phase (via auto.cmd) and then quit.
This allows a seamless upgrade experience with no intermediary prompts.

As a bonus, you can set lang, edition, arch, key to upgrade to a different edition than the current one!
I have done plenty of such upgrades today going forward and backward from/to 20H1/20H2/21H1 switching edition several times - since all have the same 19041 base, means you get full upgrade with files, apps and settings saved (if lang and arch are compatible).

Try it out just by renaming the script to auto MediaCreationTool.bat - by default starts upgrade to 21H1
Can also add the numeric version target: auto 2004 MediaCreationTool.bat or auto 2009 MediaCreationTool.bat

For those that use the script as-is, these enhancements do not affect the workflow in any way.
Script will simply pass control to MCT and quit early as before.

@jschultz0614

This comment has been minimized.

Copy link

@jschultz0614 jschultz0614 commented Mar 29, 2021

is it possible to specify the product key at the command line as well as the choice as to what to do (I.E. create an ISO file and the name of the ISO file to create)? Also, is it possible to create a multi-product ISO and slipstream it?

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Mar 31, 2021

@jschultz0614, I already added support for supplying version both numeric and codename, as well as edition (unpublished).
I could add support for supplying a key.
Skipping to iso creation with a provided name is unfortunately not supported by MCT. Not sure dual-arch is achievable either.
You might want to look at other scripts for that kind of automation such as ESD2ISO

@TTonsfeldt

This comment has been minimized.

Copy link

@TTonsfeldt TTonsfeldt commented Apr 2, 2021

Fully Auto In-Place Upgrades from Windows 7 to Windows 10 with the last update with no edits to the batch file body.

Change the batch file name to auto 1909 MediaCreationTool.bat with automation

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented May 22, 2021

Many enhancements added!
Auto Upgrade should work without any prompts on most scenarios as @TTonsfeldt said.
Now also usable from Embedded / PosReady7 host where default MCT fails / can't upgrade keeping files and apps.
ProfessionalWorkstation or ProffesionalEducation can be used under windows via auto.cmd (indexes are not available for clean installs).
Dynamic Update if enabled, works as intended - unchanged iso / usb with the last esd + local update when launched from auto.cmd.
More arguments parsed from script name: MCT version, AUTO or ISO action, UPDATE (Dynamic Update), EDITION, KEY, LANGCODE, ARCH
Windows 10 Cross-edition upgrade / in-place upgrade / downgrade / repair, with automatic EditionID registry override
Feedback is welcome if having any issue or even if not having issues ;)

@warezdk

This comment has been minimized.

Copy link

@warezdk warezdk commented May 24, 2021

@AveYo

Hi

Cool piece of work with this Tools. :-)
Can you in any way make one that can make all versions with 32 bit + 64 bit so that this takes all versions so you do not only have to choose between Enterpirse + Pro + Education or Home etc.

When to create a new USB or iso file.

Could be cool to get them all on a USB keys.
Hope you understand me?

Thanks in advance for the fine work.

@Dezirdt-Uzurnaim

This comment has been minimized.

Copy link

@Dezirdt-Uzurnaim Dezirdt-Uzurnaim commented May 27, 2021

Using the latest revision. Logged in as a standard user and running script as Administrator, we receive a dialog prompt stating the application must be run as an Administrator. Thoughts?

image

Screenshot 2021-05-27 080803

@Dezirdt-Uzurnaim

This comment has been minimized.

Copy link

@Dezirdt-Uzurnaim Dezirdt-Uzurnaim commented May 27, 2021

Using the latest revision. Logged in as a standard user and running script as Administrator, we receive a dialog prompt stating the application must be run as an Administrator. Thoughts?

image

Screenshot 2021-05-27 080803

Running as SYSTEM via SCCM/MEM deployment worked like a charm.
The new mechanics worked flawlessly for bypassing the prompts!!

Well done, Good Sir!

@Gitouttamyfollicles

This comment has been minimized.

Copy link

@Gitouttamyfollicles Gitouttamyfollicles commented Jun 11, 2021

Sorry to ask a dumb question, but I want to be able to just download W10 versions, not necessarily install as well. And this, if possible, from a W7 PC. Is that possible with this script?

@Karl-WE

This comment has been minimized.

Copy link

@Karl-WE Karl-WE commented Jun 12, 2021

yes it is. But you can also just go here https://www.microsoft.com/software-download/windows10 and choose download tool.
It is technically still possible to upgrade 7 and 8.1 to 10 21H1. And worth it too. This tool would be only needed if you need a specific older version for testing purposes, as the official tool will only download the latest release one.

@Gitouttamyfollicles

This comment has been minimized.

Copy link

@Gitouttamyfollicles Gitouttamyfollicles commented Jun 12, 2021

Thanks, Carl. I see I could have explained myself better.
I'm not intending to install W10 onto my W7 machine, just store the file or files there until I need them.
And re the MS site you linked, I thought that the download options are restricted from MS?

@DoctorDisco13

This comment has been minimized.

Copy link

@DoctorDisco13 DoctorDisco13 commented Jun 14, 2021

Hi,
I m seeking to launch this script on a distant machine with CMD or PS to upgrade to 2104 /default without any user interaction, but i can't find the right parameters.
Can someone help me pls
Thanks in advance.

@Karl-WE

This comment has been minimized.

Copy link

@Karl-WE Karl-WE commented Jun 15, 2021

I thought that the download options are restricted from MS? > yes the offical tool only downloads the latest release.
@Gitouttamyfollicles

@Gitouttamyfollicles

This comment has been minimized.

Copy link

@Gitouttamyfollicles Gitouttamyfollicles commented Jun 17, 2021

Thanks, Carl, I thought it was something like that.

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Jun 20, 2021

@DoctorDisco13, download the script, rename it to auto MediaCreationTool.bat and run it. That should do it (if there are no compatibility issues)

@michelle1574

This comment has been minimized.

Copy link

@michelle1574 michelle1574 commented Jun 27, 2021

@AveYo add Insidder/Technical Preview versions, avaible in tb.rg-adguard.net / Electronic software download

@michelle1574

This comment has been minimized.

Copy link

@michelle1574 michelle1574 commented Jun 27, 2021

Something's wrong with downloader. I choosed 1507 Create-media but on CMD sowed Enterprise

@michelle1574

This comment has been minimized.

Copy link

@michelle1574 michelle1574 commented Jun 27, 2021

@AveYo Add ARM and ARM64 support if possible

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Jul 6, 2021

@michalpustelnik7209: 1507 does not have public Enterprise ESD, that's just your current edition probably (auto-detected).
After this new update the displayed edition will more closely match the media.
I do have arm support planned but no way of testing (and already behind on that as I've been having a hard time these past months).
Hope all is well with this update, and thanks for your input!

@michelle1574

This comment has been minimized.

Copy link

@michelle1574 michelle1574 commented Aug 1, 2021

Could you add Windows 8.1 with Update 1, 2 and 3?
Get ESD links on tb.rg-adguard.net
Select ESD and you should select these versions

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Aug 1, 2021

I'm aware there are other public esd's, but this script focuses on windows 10
8.1 imho is meh, with less hardware support, even more unoptimized telemetry and updates, and plagued by uac and privilege escalation flaws

@Karl-WE

This comment has been minimized.

Copy link

@Karl-WE Karl-WE commented Aug 3, 2021

on the top of that 8.1 is in extended support, means no support except you throw a bunch of $$$ towards MS support with no obligation for them to fix anything. End of Support is near too.

@jmroyb

This comment has been minimized.

Copy link

@jmroyb jmroyb commented Aug 24, 2021

Do you plan publish the universal MediaCreationTool wrapper for all MCT Windows 11 versions?

Thanks

@ghost

This comment has been minimized.

Copy link

@ghost ghost commented Sep 9, 2021

Microsoft already deleted windows 7 from site and this old windows 10 versions also will be deleted on https://microsoft.com

@ghost

This comment has been minimized.

Copy link

@ghost ghost commented Sep 9, 2021

From 1703 MediaCreationTool not working!

@MarlonPra

This comment has been minimized.

Copy link

@MarlonPra MarlonPra commented Sep 10, 2021

From 1703 MediaCreationTool not working!

I mean that MediaCreationTool will not be updated in the future?

@jschultz0614

This comment has been minimized.

Copy link

@jschultz0614 jschultz0614 commented Sep 10, 2021

@ghost

This comment has been minimized.

Copy link

@ghost ghost commented Sep 11, 2021

From 1703 MediaCreationTool not working!

I mean that MediaCreationTool will not be updated in the future?

It says to download a new MediaCreationTool so 1703 and higher not working

@ghost

This comment has been minimized.

Copy link

@ghost ghost commented Sep 11, 2021

https://docs.microsoft.com/en-us/lifecycle/products/windows-10-home-and-pro
https://docs.microsoft.com/en-us/lifecycle/products/windows-81
Microsoft will continue to support at least one Windows 10 Semi-Annual Channel until October 14, 2025.

@ghost

This comment has been minimized.

Copy link

@ghost ghost commented Sep 17, 2021

Could you add Windows 8.1 with Update 1, 2 and 3?
Get ESD links on tb.rg-adguard.net
Select ESD and you should select these versions

Windows 8.1 is here https://www.microsoft.com/en-us/software-download/windows8ISO

@ghost

This comment has been minimized.

Copy link

@ghost ghost commented Sep 17, 2021

Only works 1507 and 1607 Media Creation Tool! Other like 1511 and other not working only last new!

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Sep 25, 2021

@ghost, thanks for reporting! this latest version should be fine, just done a 1511 and a 1703 iso via default option (Create USB)

I had Windows 11 support added since September 3th, but decided to hold on to it.
Since then I have refined the script so it should be much more reliable, just like in the past.
Check it out!

Note that for 11 there is no MCT released yet publicly, so I'm using the windows 10 one - it's absolutely fine, just that it writes as "10"..

@ghuntley

This comment has been minimized.

Copy link

@ghuntley ghuntley commented Sep 29, 2021

https://gist.github.com/AveYo/c74dc774a8fb81a332b5d65613187b15#file-skip_tpm_check_on_dynamic_update-cmd works lovely to install win11 updates on win11 VM without TPM. Thanks :)

@Karl-WE

This comment has been minimized.

Copy link

@Karl-WE Karl-WE commented Sep 29, 2021

@Guntley even if you can install W11 without TPM this does not mean it is a good idea. You will not get any updates on this version if your CPU does not match the requirements. TPM was the most discussed but the easiest to fix issue (along UEFI / SecureBoot)
try WhyNotWin11 on Github to check your compatiblity.

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Sep 29, 2021

@Karl-WE

even if you can install W11 without TPM this does not mean it is a good idea. You will not get any updates on this version if your CPU does not match the requirements. TPM was the most discussed but the easiest to fix issue (along UEFI / SecureBoot) try WhyNotWin11 on Github to check your compatiblity.

sorry, that's FUD atm (edit: from microsoft, to be clear), no matter how you got windows 11 installed, you do get updates (LCUs and what not)
it's only "feature upgrades" being blocked i.e. newer insider builds (that this script also unblocks).
microsoft cant afford making drastic changes about it that would equal purposely generating critical mass of outdated machines

also, @ghuntley looks to already be taking precautions by running 11 in a VM.
and there's no freakin legit reason why microsoft should ever block that scenario. ever

@markuznw

This comment has been minimized.

Copy link

@markuznw markuznw commented Sep 29, 2021

How's this supposed to work? Tried pressing 11 then auto and it downloads MCT 21H1 and upgrades to it (actually rolling back from 21H2). Can't get how to make it work honestly

And what about the insider upgrade? Can't even roll inside 11 insider without requirements

@Karl-WE

This comment has been minimized.

Copy link

@Karl-WE Karl-WE commented Sep 29, 2021

@AveYo. They do and I am currently in the process to flag with local consumer rights organisation and responsible teams at EU level to have that cleared. Will not provide any other information for reasons now.
Windows 11 Devices that are installed on unqualified hardware will not receive updates. The message is clear in Setting app in beta channel.
It is even said they will not get any upgrades after 2023 (23H2). You must accept the warning from setup.exe.

There are two workarounds to this to install W11 on unqualified hardware, but they are workarounds. I cannot tell yet, what will happen in future (if I could I would apply for a different job).

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Sep 29, 2021

@markuznw - if your current windows is borked, then upgrading would likely fail no matter what target version.
that's when you have to do a fresh install via bootable usb / dvd from iso
so use Create USB / Create ISO instead then boot from usb / dvd burned from the iso file

as for joining the insider program to get dev / beta builds without having the system requirements,
there are scripts such as OfflineInsiderEnroll that you could use

@AveYo

This comment has been minimized.

Copy link
Owner Author

@AveYo AveYo commented Sep 29, 2021

@Karl-WE, like I've said it is marketing FUD. Won't actually come to that October 5th and beyond.
I refuse to believe microsoft can be that stupid (tho I'm not dismissing it completely).
And as of now, the bypass is viable for 22H1 builds. Who cares about 2023? That's like crystal-ball worrying. Let's tackle problems as they come.

@Karl-WE

This comment has been minimized.

Copy link

@Karl-WE Karl-WE commented Sep 29, 2021

@markuznw what is the setupdiag output for your inplace upgrade rollback? Have you tried it (I do not want to troubleshoot and derail the idea of this commenting on the product, tho.

@legaleye3000

This comment has been minimized.

Copy link

@legaleye3000 legaleye3000 commented Sep 30, 2021

@AveYo just following up on @markuznw response and your response. I just installed win10 brand new into a VM. I ran your script using administrator. When I launch MCT and choose Windows 11, it says its downloading Windows 10. Just confirming that Windows 11 is actually downloading even though it says Windows 10 is downloading? Thank you!

@jschultz0614

This comment has been minimized.

Copy link

@jschultz0614 jschultz0614 commented Sep 30, 2021

@jschultz0614

This comment has been minimized.

Copy link

@jschultz0614 jschultz0614 commented Sep 30, 2021

@AveYo, Thanks for your reply. For some reason, the version I have (and I will agree that it might be out of date) does have the ability to create either an ISO image or USB Key image.

I have no idea why mine has these enabled, yet here we are. :p

@davidpalacin

This comment has been minimized.

Copy link

@davidpalacin davidpalacin commented Sep 30, 2021

Hi all.

Im Ryzen 7 1700 user so i need to skip the hardware checking.
Yesterday i'd downloaded and executed the project and im getting a strange result, i mean:
I wanted to test the "download iso" option, just for saving in Download folder an iso, but i had to cancel the download. I did anything more with your project.
When im back, i check the "normal" windows Updater (im insider in beta channel) and i see an update avaliable for Windows 11.
My question is that, i dont understand if i canceled the iso's download why i did get this upgrade, i dont know if that was for the project or was just a coincidence and in a casuality Microsoft is testing Ryzen series 1000.

@marcopaone

This comment has been minimized.

Copy link

@marcopaone marcopaone commented Sep 30, 2021

Hi!
Not working. Can't download files...
image

@ghost

This comment has been minimized.

Copy link

@ghost ghost commented Sep 30, 2021

@Mennaruuk

This comment has been minimized.

Copy link

@Mennaruuk Mennaruuk commented Sep 30, 2021

Auto setup doesn't work for me :( MCT downloads and processes Windows 11 ISO, but then it disappears, and I can't find the ISO anywhere, nor does setup start.

Is there a video tutorial, or any workaround to solve this problem? More then happy to provide any info, thank you!

@markuznw

This comment has been minimized.

Copy link

@markuznw markuznw commented Sep 30, 2021

@markuznw - if your current windows is borked, then upgrading would likely fail no matter what target version. that's when you have to do a fresh install via bootable usb / dvd from iso so use Create USB / Create ISO instead then boot from usb / dvd burned from the iso file

as for joining the insider program to get dev / beta builds without having the system requirements, there are scripts such as OfflineInsiderEnroll that you could use

Thanks for your reply. As per @Mennaruuk and other users replies there are some issues with the Auto function. It said Windows 10 MCH (which I got you use as a "ftp" to download a specific image) and in console, just after selecting 11 and "Auto" it said 21H1 with the 11 build near but then, like said, it downloads 21h1 or just triggers windows to reinstall 21h1 (I have got no idea).

Everything solved by your input of using offline inside reenroll + windows update and the script to enable dynamic updates, guess tho auto function needs investigating/fixing further

@Mennaruuk Yes i had the same several times while trying, a windows 11 popup that didn't do anything for hours... had to close it manually every time or it just disappeared after a while

@Eclipswf

This comment has been minimized.

Copy link

@Eclipswf Eclipswf commented Sep 30, 2021

::# Nothing but Microsoft-hosted source links and no third-party tools - script just configures a xml and starts MCT
::# Ingenious support for business editions (Enterprise / VL) selecting language, x86, x64 or AiO inside the MCT GUI
::# Changelog: 2021.09.25 Windows 11
::# - improved script reliability; create iso directly; enhanced dialogs; args from script name or commandline
::# - 11: 22000.132 / 21H2: 19044.1165 / 21H1: 19043.928 / 20H2: 19042.1052 / 2004: 19041.572 / 1909: 18363.1139

::# uncomment to skip gui dialog for MCT choice: 1507 to 2109 / 11 - or rename script:  "21H2 MediaCreationTool.bat"
rem set MCT=2109

::# uncomment to start auto upgrade setup directly without prompts - or rename script:  "auto MediaCreationTool.bat"
rem set/a AUTO=1

:: uncomment to start iso file creation directly without prompts - or rename script: "iso 11 MediaCreationTool.bat"
rem set/a ISO=1

::# uncomment and change autodetected MediaEdition - or rename script:   "enterprise iso 2009 MediaCreationTool.bat"
rem set EDITION=Enterprise

 Auto Version  20H2  tr-TR  Professional  x64 ~

 CANCELED```
@grazianoitalia

This comment has been minimized.

Copy link

@grazianoitalia grazianoitalia commented Sep 30, 2021

I need help. I try to executye the batch but apparently nothing happened, if now I try to execute newsly the batc I get the result "CANCELED" what is gone wrong??
2021-09-30_19-02-26
?

@nana170

This comment has been minimized.

Copy link

@nana170 nana170 commented Sep 30, 2021

bonsoir est ce que quelqu un pourrait aide a installe windows car j ai un probleme de prise en charge du choffrement est de ma configuration pcr 7 et aussi mon dma est deactive et aussi mon mode de vertualisation et mon processeur n est pas pris en charge ni mon tpm bien cordialement

@nana170

This comment has been minimized.

Copy link