Microsoft took a serious look at how to save space from the operating system files with Windows 8.1 Update. What they came up with at the time was WIMBoot, which used the recovery partition’s compressed WIM image file as the basis for most of the system files needed by Windows. Since the recovery partition is at least 4 GB in size, this is a pretty substantial savings especially on the lower cost devices which WIMBoot was targeted at.

I’ve discussed the changes with Windows 10 a couple of times, but a recent blog post from Michael Niehaus outlines how the new system works, what it is called, and how to manually enable it.

The last bit there is pretty important, since moving to WIMBoot was not something that could be done easily. It had to be done at the time the system image was put onto the computer, and there were a couple of extra steps OEMs could take in order to incorporate their own software into the WIMBoot.

Standard Partition with Windows 8.1

WIMBoot Enabled Windows 8.1

This also lead to some of the first issues with WIMBoot. The actual size of the recovery partition, if it was just Windows, would be around 4 GB, but once an OEM adds in their own software, along with maybe a copy of Microsoft Office, and all of a sudden the recovery partition could bloat to 10 GB or more. This was a major issue because unlike with a standard install of Windows, the recovery partition can not be removed on a WIMBoot system leaving a large chunk of a possibly small drive used up with no way to reclaim that space.

The other issue was that over time the WIMBoot partition would become less and less used, since when there were security updates to the operating system, key system files would be replaced with a full uncompressed version, but the original version would still be part of the WIM which could not be modified. Over time, Windows would grow and grow to fill more and more of the drive, and the WIMBoot concept was clearly not working out as intended.

So with Windows 10, Microsoft has moved away from the recovery partition altogether. When you do a system reset, Windows will be rebuilt from the components in the \Windows\winsxs folder. This means that the system will also be almost fully patched after a reset, unlike with earlier versions of Windows where any restore off of the recovery partition would revert you back to whatever set of files was used to create the WIM. Only the most recent 30 days of patches will be installed, and this was a design decision in case the reset itself is due to something going wrong within the last 30 days.

The other part of the space savings is from a compression tool Microsoft is calling Compact OS. This kind of goes back to WIMBoot in a way, since the system files are compressed into what amounts to a WIM file. The big difference here is that unlike WIMBoot, CompactOS can be enabled and disabled on the fly.

From an administrative command prompt, simply use the commands:

Compact.exe /CompactOS:query

This will query Windows to see if CompactOS is enabled or not

Compact.exe /CompactOS:always

This will enable CompactOS

Compact.exe /CompactOS:never

This will disable CompactOS

I ran CompactOS on an ASUS TP200S which has 64 GB of eMMC storage. Windows 10 did not enable CompactOS automatically since it was not needed, but manually enabling it saved over 3 GB of space on the C: drive. Luckily ASUS has included enough storage in the TP200S where it’s not really necessary out of the box, but on any system with 32 GB or less this could be a big help.

There is going to be a performance impact of course since the files will need to be decompressed when accessed and the actual differences are something I hope to have a chance to test and document at some point in the not too distant future.

In the end, CompactOS looks to be a nice upgrade over WIMBoot which had a lot of promise, but was not as effective as hoped.

Source: TechNet

Comments Locked

67 Comments

View All Comments

  • CaedenV - Friday, October 2, 2015 - link

    +1 under the advanced options you can remove old update files, previous versions of Windows, and all sorts of things that cause bloat.
    Also, if you are running with 8GB of RAM or more (and what good nerd does not have their wife on at least 8GB of ram?) then you can disable the page file. Once disabled you can delete it and bam, lots of free space opens up (equal to the amount of ram installed... so 8+GB).
  • Alexvrb - Friday, October 2, 2015 - link

    Disabling the page file is not the best advice anymore, for modern versions of Windows. Frankly if handled correctly I'm not convinced it was ever good advice to disable it entirely. Unless you're REALLY REALLY desperate for storage space and yet somehow have gobs of RAM. Anyway here's the thing: Windows intelligently stores only the least used stuff in your pagefile, so anything you actually need stays in RAM (unless you run out, in which case the pagefile would be saving your bacon anyway). It also provides a nice safety blanket against a hard program crash and doesn't hurt anything... except a little storage. I'd rather use Win10's CompactOS option and just about any other tweak instead of disabling paging.
  • blahsaysblah - Saturday, October 3, 2015 - link

    You have serious miss-understanding what a pagefile is and its purpose and how it functions inside the VMM domain.

    Pagefile bad.

    If you dont have a lot of RAM. Its actually even better to turn off pagefile and than figure out what to stop doing/running. You absolutely never want to use a pagefile. Especially on weaker systems.
  • Kvaern2 - Saturday, October 3, 2015 - link

    Amen, I haven't used a pagefile since Win2K and haven't experienced a single issue because of it.
  • doggface - Saturday, October 3, 2015 - link

    Sorry. But I call Bulls%%t.
    A small pagefile (30-60%) of RAM size is absolutely a good idea for overflow protection, and has virtually no downside. (Especially on an SSD)

    If you want to be a super neck beard about it then put the pagefile on a ram disk, but removing the pagefile... Is absurd and self-defeating.
  • Reflex - Monday, October 5, 2015 - link

    As a former kernel engineer for Windows Thanks to those discrediting the 'disable the page file' crowd. That and most tweaking ceased to have any real world benefit with the move from Win9x (which I worked on) to Windows XP (which I also worked on). At best a user gains no positive impact. At worst you get random bad behavior that you may or may not realize is due to your tweaks.
  • CaedenV - Friday, October 2, 2015 - link

    Interesting. I did it on mine and it is enabled even though I have a lot of space (512GB SSD), I wonder why that was turned on by default, and if that has any kind of performance hit... granted, still faster than win7 on the same box so I guess I can eat that performance hit for the sake of a few extra GB of space
  • blahsaysblah - Saturday, October 3, 2015 - link

    Windows pagefile's purpose is purely to give you more "simulated" RAM via your HDD/SDD.

    You should never be using simulated RAM.

    The concept was created many decades ago to allow completion of batch jobs that ran over days/weeks. Your PC activity is meant to be reactive.

    Turn off pagefile always. If you dont have enough RAM to run your workflow, change your workflow to fit in you RAM. Not the other way around. Many orders of magnitude difference.

    Its never OK to to have a pagefile on a PC.

    And you dont delete pagefiles... For very long time. Disable it and windows deletes it. If you are talking about hibernate file, just issue "powercfg /h off" in an Admin CMD shell. That also does not require manual deletion.
  • jabber - Saturday, October 3, 2015 - link

    If you look up on the MS websites you'll find that the Pagefile is pretty much just there for crash dumps and any old legacy software that has to detect if a Pagefile exists on the system without having a hissy fit. Otherwise it's redundant.
  • DanNeely - Saturday, October 3, 2015 - link

    Which is a worse user experience? Inadvertantly exceeding your total physical ram limit and having things start to slow down because stuff is being swapped, or to have software randomly crash because allocations fail with no warning/explanation of what's going on? A few months ago I had the "pleasure" of dealing with the latter on an older box following it's being upgraded to W7 by someone with the same misguided attitude about page files despite the box not having enough ram to run all the software we needed without on concurrently. It was hell until we got it turned back on, 10-25% swap usage is barely noticeable. (Although the version N+1 memory requirements for one piece of software we use jumped by enough to finally overcome if it aint broke don't replace it inertia and have hardware upgrades finally get scheduled for the workstations.)

    By all means, size your ram large enough that you shouldn't exceed it in normal operation; but leave it on so your system doesn't start blowing up if you end up using too much stuff.

Log in

Don't have an account? Sign up now