SOLVED: Windows 10 1803 Upgrade with winpeshl.ini Issue

Update, 18.06.2018, by Microsoft:
We are aware of an issue affecting the recent media on VLSC. The ISO has been replaced on VLSC.  If you have encountered issues installing with this media, we recommend you download and install the refreshed ISO now available on VLSC or wait until we release a new version later in June.

This blog post will be a short one. I just would like to publish my workaround regarding Windows 10 1803 upgrade issue.

Issue: after the upgrade, I’ve received this prompt message “A winpeshl.ini file is present, but no commands were successfully launched. This could be caused by incorrect formatting or an invalid executable name.” It may result from a corrupted installation file, which lead to failure during setup.

This seems to be a problem with the current install media from VLSC (filename SW_DVD9_Win_Pro_Ent_Edu_N_10_1803_64BIT_English_-3_MLF_X21-82160.iso).  It doesn’t matter if you run the upgrade through SCCM or just mount the ISO and run it through the GUI, it fails just like this. If you have a previous ISO version SW_DVD9_Win_Pro_Ent_Edu_N_10_1803_64BIT_English_-3_MLF_X21-79647.iso it will work.

Microsoft says: We are aware of the issue and are investigating solutions. Will update when we know more. (Wednesday, June 13, 2018 12:15 AM)

Solution 1: when it gets hung at the command prompt after the first reboot.

  • Just search for RecEnv.exe 
    dir RecEnv.exe /s
  • Jump to that directory
  • Run this file
  • Setup will now continue!

Solution 2: modify install.wim file.

  • Mount boot.wim from the ISO
    dism /mount-image /imagefile:"C:\W10_1803\sources\boot.wim" /mountdir:"C:\W10_1803\MountBOOT" /index:1
  • Check install.wim for indexes
    dism /get-wiminfo /wimfile:"C:\W10_1803\sources\install.wim"
  • Choose and mount your correct index
    dism /mount-image /imagefile:"C:\W10_1803\sources\install.wim" /mountdir:"C:\W10_1803\Mount" /index:3
  • Mount winre.wim from mount directory
    dism /mount-image /imagefile:"C:\W10_1803\Mount\Windows\System32\Recovery\Winre.wim" /mountdir:"C:\W10_1803\MountWINRE" /index:1
  • Copy sources folder
    cpi -Path C:\W10_1803\MountBOOT\Sources -Destination C:\W10_1803\MountWINRE -Recurse
  • Unmount winre.wim file with commit command
    dism /unmount-image /mountdir:"C:\W10_1803\MountWINRE" /commit
  • Unmount install.wim file with commit command
    dism /unmount-image /mountdir:"C:\W10_1803\Mount" /commit
  • Unmount boot.wim file
    dism /unmount-image /mountdir:"C:\W10_1803\MountBOOT" /discard

For sure, I prefer the solution 2. Because now you are able to update your deployment with this new modified install.wim media and automatize your upgrade process.

Until Microsoft is not updating this ISO file on the VLSC paltform, we have to work with this workaround. I hope this helps you!

29 Comments


    1. Solution 2, are they command or? how did you do it?

      Reply

  1. I got “‘cpi’ is not recognized as an internal or external command,
    operable program or batch file. error.” Can you help please?

    Reply

    1. You can use Copy-Item, Copy or CP as standard aliases too.

      Reply

      1. Thank you! I managed to run the cpi command from Powershell, but this time I am getting “Access Denied” errors while copying source files to destination. What can I do to fix this issue?

        Reply

  2. Solution1 works like a charm – many thx

    Reply

  3. Both Solutions are working.

    I have used power shell command(Copy-Item “C:\W10_1803\MountBOOT\sources” -Destination “C:\W10_1803\MountWINRE” -Recurse) for copy the files

    Thank You !

    Reply

  4. that worked!
    thanks for the info!

    Reply

      1. What do i have to type in cmd to run the file?

        Reply

        1. powershell.exe -command “& {Add-AppxProvisionedPackage -Online -PackagePath “X:\x86fre\Microsoft.WindowsStore_8wekyb3d8bbwe.appxbundle” –LicensePath “X:\x86fre\Microsoft.WindowsStore_8wekyb3d8bbwe.xml”}”

          Reply

  5. What do I do after the first solution, do I wait or do a command, please help me.

    Reply

    1. Hi Jack, try to run this newly founded RecEnv.exe; with the correct path.

      Reply

      1. What does that mean, im sorry im not that tech person that knows everything, could you explain it to me please.

        Reply

        1. Which kind of W10 editions do you have? Home, Pro or Enterprise?
          In which phase do you have this issue? OSD setup, feature upgrade?

          Reply

          1. I believed I had a Pro Edition, or a home. I haven’t checked but I think i have pro.


  6. I just picked up a Lenovo ThinkPad from a thrift store when I got it powered up and tapped F9 at first screen I found “computrace” and then some how ended up at the “Administrator:X:\windows\system32\cmd.exe” screen with the same message anyone have suggestions? I’m kinda worried about putting in any commands at this point.

    Reply

  7. I just picked up a Lenovo ThinkPad from a thrift store when I got it powered up and tapped F9 at first screen I found “computrace” and then some how ended up at the same screen with the same message anyone have suggestions? I’m kinda worried about putting in any commands at this point.

    Reply

  8. Hi for solution 1 ..it says file not found.

    Reply

  9. please help me what to do after writing
    dir /s *recenv.exe*
    how do I jump to that directory?

    Reply

    1. Simply use “cd” command and copy-paste the target directory where the correct RecEnt.exe can be found.

      Reply

  10. Hi, I have a same problem. I wrote the command in your screeenshot. Now, my CMD screen looks same but I don’t know what I will do after that.. Im not very well on CMD copy paste things. Please help me.. thanks ..

    Reply

  11. I’m using a modified ISO and i’m not sure what to do next.

    I use solution 1, setup opens, but at the next screen it says “exit and continue install setup” and i get the same error again.

    As it comes with solution 2 i’m not sure how to write the first comand

    Reply

  12. It’s now March 2021 and I have just encountered this problem for the first time with a Windows 10 update. Hoping your solution still works. Will give it a go.
    Thanks.

    Reply

Leave a Reply to Hasan Cancel reply

Your email address will not be published. Required fields are marked *