Adding PowerShell support to Windows PE

email me

Step 1 – Download the WAIK Tools

Step 2 – Create folder structure C:\WinPE\mount

Step 3 – Move a copy of your boot.wim into C:\WinPE

Step 4 – Open admin command prompt

Step 5 – copype amd64 C:\WinPE

Step 6 – Run the following commands in the console

Dism /Mount-Image /ImageFile:”C:\WinPE\boot.wim” /Index:1 /MountDir:”C:\WinPE\mount”

Dism /Add-Package /Image:”C:\WinPE\mount” /PackagePath:”C:\Program Files\Windows Kits\8.1\Assessment and Deployment Kit\Windows Preinstallation Environment\amd64\WinPE_OCs\WinPE-WMI.cab”

Dism /Add-Package /Image:”C:\WinPE\mount” /PackagePath:”C:\Program Files\Windows Kits\8.1\Assessment and Deployment Kit\Windows Preinstallation Environment\amd64\WinPE_OCs\en-us\WinPE-WMI_en-us.cab”

Dism /Add-Package /Image:”C:\WinPE\mount” /PackagePath:”C:\Program Files\Windows Kits\8.1\Assessment and Deployment Kit\Windows Preinstallation Environment\amd64\WinPE_OCs\WinPE-NetFX.cab”

Dism /Add-Package /Image:”C:\WinPE\mount” /PackagePath:”C:\Program Files\Windows Kits\8.1\Assessment and Deployment Kit\Windows Preinstallation Environment\amd64\WinPE_OCs\en-us\WinPE-NetFX_en-us.cab”

Dism /Add-Package /Image:”C:\WinPE\mount” /PackagePath:”C:\Program Files\Windows Kits\8.1\Assessment and Deployment Kit\Windows Preinstallation Environment\amd64\WinPE_OCs\WinPE-Scripting.cab”

Dism /Add-Package /Image:”C:\WinPE\mount” /PackagePath:”C:\Program Files\Windows Kits\8.1\Assessment and Deployment Kit\Windows Preinstallation Environment\amd64\WinPE_OCs\en-us\WinPE-Scripting_en-us.cab”

Dism /Add-Package /Image:”C:\WinPE\mount” /PackagePath:”C:\Program Files\Windows Kits\8.1\Assessment and Deployment Kit\Windows Preinstallation Environment\amd64\WinPE_OCs\WinPE-PowerShell.cab”

Dism /Add-Package /Image:”C:\WinPE\mount” /PackagePath:”C:\Program Files\Windows Kits\8.1\Assessment and Deployment Kit\Windows Preinstallation Environment\amd64\WinPE_OCs\en-us\WinPE-PowerShell_en-us.cab”

Dism /Add-Package /Image:”C:\WinPE\mount” /PackagePath:”C:\Program Files\Windows Kits\8.1\Assessment and Deployment Kit\Windows Preinstallation Environment\amd64\WinPE_OCs\WinPE-StorageWMI.cab”

Dism /Add-Package /Image:”C:\WinPE\mount” /PackagePath:”C:\Program Files\Windows Kits\8.1\Assessment and Deployment Kit\Windows Preinstallation Environment\amd64\WinPE_OCs\en-us\WinPE-StorageWMI_en-us.cab”

Dism /Add-Package /Image:”C:\WinPE\mount” /PackagePath:”C:\Program Files\Windows Kits\8.1\Assessment and Deployment Kit\Windows Preinstallation Environment\amd64\WinPE_OCs\WinPE-DismCmdlets.cab”

Dism /Add-Package /Image:”C:\WinPE\mount” /PackagePath:”C:\Program Files\Windows Kits\8.1\Assessment and Deployment Kit\Windows Preinstallation Environment\amd64\WinPE_OCs\en-us\WinPE-DismCmdlets_en-us.cab”

Dism /Unmount-Image /MountDir:C:\WinPE\mount /Commit