1 Working with Windows Preinstallation Environment (WinPE) – Win10.Guru
Go to ...

RSS Feed

Working with Windows Preinstallation Environment (WinPE)


There’s another version of Windows 10 that’s always around, different from the base version you boot when you fire up the normal operating system. It’s somewhat misleadingly called the Windows Preinstallation Environment. And indeed, it does provide a basic runtime environment during Windows installation that takes over from the primary OS when a new OS is being clean installed, or an existing OS is going through a major upgrade. But WinPE can do ever so much more than that. It’s the basis for the Windows Recovery Environment (often abbreviated as — you guessed it! — WinRE) that gets installed to provide an alternate runtime for OS repairs and investigations. The folks at Macrium posted a blog this week entitled “What else can I do with WinPE?” It outlines some useful applications for WinPE, and got me to thinking about the many ways in which I’ve used WinPE/WinRE over the years to bail myself out of various kinds of Windows Trouble.

Working with Windows Preinstallation Environment (WinPE).screencap

While it’s running, WinPE can look like any other command prompt.
The X: drive letter shows that you’ve booted from alternate media, into an alternate OS.
[Source: MS Docs WinPE]

What the Macrium Post Suggests

Beyond mentioning the value of Macrium Reflect’s own Rescue Media (a personal fave) and its ability to restore images, “Fix Windows Boot Issues,” and make use of “Macrium ReDeploy” to deploy OSes on one or more PCs, the company suggests several other uses for WinPE worth remembering (and using) when Windows gets wonky, as it sometimes can do. These suggestions, as you might expect, focus on certain other things that only Rescue Media can do as well as some good general-purpose applications. Here they are, in annotated bullet form:

– Imaging without 3rd-party interference: Reflect may be impeded or blocked by third-party programs such as anti-virus. If you boot to the Rescue Media, none of that stuff will run. Thus, it also can’t get in the way. This makes restoring backups while booted from the Rescue Media particularly adept at avoiding 3rd-party interference.
– Imaging sans VSS: The Volume Shadow Service provides a means to make a static snapshot of a dynamic OS and file system while that system is running. Sometimes, however, issues with VSS can present and prevent Reflect from properly doing its thing. Because the usual OS isn’t running when one boots from Rescue Media, it can image that OS without using VSS. This provides a way to make a backup even when VSS isn’t working properly on a particular PC. Problem-ridden PCs make especially good candidates for backup, for what I hope are obvious reasons.
– Troubleshooting and repairing: The WinPE environment provides access to a command prompt, from whence one can run all kinds of powerful and useful utilities, such as chkdsk, diskpart, bcdedit, bootrec, and DISM, not to mention the vast majority of other familiar built-in commands. This means you can work on a damaged or non-bootable OS even though the target of your efforts may not work well or at all on its own.
– Access to logs and diagnostics: In the troubleshooting sequence, identifying the source of problems or issues is an important step. Key information for such diagnosis often comes from logs that Windows creates and builds as errors or issues occur. WinPE lets you access and copy those log files, so that you can inspect them for useful information, or share them with trained professionals who can understand their nuances at the deepest and most informative levels.
– File recovery: If all else fails, Macrium’s Rescue Media includes a basic, built-in file explorer that can get to and copy files — even from usually inaccessible partitions like the MSR and EFI partitions — so they can be saved from permanent loss, if you must wipe the drive (or trash it) when other recovery methods don’t work.

These are all good suggestions, and because I use Macrium Reflect and its Rescue Media, I’ve used all of them directly myself.

Other WinPE Tools and Uses

Elsewhere here at Win10.Guru, I’ve written about a Toolkit Item called “Kyhi’s Rescue Disk.” This is a highly customized version of WinPE that not only includes command line access and its other usual capabilities, but also incorporates a boatload of applications for repair and recovery purposes, including Macrium Reflect itself. It includes around 70 applications, with lots of notable items available, such as 7-Zip, CCleaner, CPU-Z, Defraggler, EasyBCD, HDTune, MTPW, ShowKeyPlus, and many more. While I’ve certainly used Macrium’s Rescue Disk on numerous occasions, I’ve used Kyhi’s Rescue Disk even more often. Shoot, even a bootable Windows Installer will give you basic command line access in a boot session, as well as basic boot and other repair utilities.

Over the years, I’ve turned to WinPE to help me delete files left over from previous Windows installs that Disk Cleanup won’t extirpate. Ditto for certain stubborn driver and cab files that sometimes show up through updates or Windows Update and simply won’t go away when their usability or relevance is long gone. Booting to a different OS reduces the built-in protections for system files and directories that a running Windows otherwise exercises on its own behalf. As long as you’re careful and responsible about what you get rid of when you’ve booted into WinPE to work on the main OS, you can delete just about anything your little heart desires in that mode of operation.

In short, WinPE is a worthwhile alternate boot environment for any Windows PC. It’s worth learning about, and learning how to use, because there are some circumstances or situations where nothing else will let you fix what’s broken. To learn more, dig into the Microsoft Docs coverage of Windows PE (WinPE) available online. It’s a real mountain of stuff, so give yourself some time to read through it and let it all sink in. Enjoy!

Author: Ed Tittel

Ed Tittel is a 30-plus-year computer industry veteran. He’s a Princeton and multiple University of Texas graduate who’s worked in IT since 1981 when he started his first programming job. Over the past three decades he’s also worked as a manager, technical evangelist, consultant, trainer, and an expert witness. See his professional bio for all the details.

One Response “Working with Windows Preinstallation Environment (WinPE)”

  1. May 10, 2019 at 21:22

    Macrium PE is my chosen tool for troubleshooting. I wrote about how to add it to your Windows boot menu just a few days ago: https://win10.guru/make-windows-boot-menu-work-for-you/

Leave a Reply