How to Compress "Bloated" Registry Hives

Applies to: Microsoft Windows Server 2003 R2 Datacenter Edition (32-Bit x86)Microsoft Windows Server 2003 R2 Enterprise Edition (32-Bit x86)Microsoft Windows Server 2003 R2 Standard Edition (32-bit x86)


Consider the following scenario:

You may discover that some of your registry hives are abnormally large or “bloated”.  Registry hives that are in this state can cause various performance issues and errors in the system log.


There can be many causes for this issue.  Troubleshooting the actual cause can be a long and tedious process.  In this scenario, you simply want to compress the registry hives to a normal state.


While there may be 3rd party tools available for this scenario, the process listed below could be followed to compress the affected hives.

1)  Boot from a WinPE disk. (
2)  Open regedit while booted in WinPe, load the bloated hive under HLKM.  (e.g. HKLM\Bloated)
3)  Once the bloated hive has been loaded, export the loaded hive as a "Registry Hive" file with a unique name.  (e.g. %windir%\system32\config\compressedhive)
      a)  You can use dir from a command line to verify the old and new sizes of the registry hives.
4) Unload the bloated hive from regedit. (If you get an error here, close the registry editor. Then reopen the registry editor and try again.)
5) Rename the hives so that you will boot with the compressed hive.
c:\windows\system32\config\ren software software.old
c:\windows\system32\config\ren compressedhive software

More Information

Related Content 
B 2903037 Cumulative list of reasons that cause a Registry BloatComprehensive list of reasons for registry bloat by rkiran circa 2013.
B 2487389 How to bloat the registryBatch file that intentionally bloats the registry for test purposes. Aaronmax.
Default script adds 250K multi-string values into the Cluster Key section of the registry. Can be repurposed for other users.
B 2278919 Print driver causing registry bloat by adding too many entries under PendingFileRenameOperationsCirca 2010 article by sumehp triggered where HP print driver created thousands of entries under pendingfilerenameoperations section of registry.
B 2720115 Registry Bloat Detection, Analysis and CorrectionCirca 2012 article by blakemo noting an array of symptoms (SBSL, no boot, high cpu. Leverages checkreg to find and cleanup the registry.
2578694 Registry bloat in HKU\.DEFAULT\Software\Hewlett-Packard\ by HPZUILHN.DLL Registry bloat under hku\.default\software\Hewlett-packard section of registry.
B 3037266 SBSL: App: WNF state registrations cause excessive reads and bloat of notifications registry hiveWNF state registrations cause boot and logon delays. Problem fixed in Windows 10 RTM. Fix was backported to 8.1 / WS12R2 by KB 3063843
B 2761589 SBSL: DISK: VSS snapshots by DPM et al bloat the system hive of the registry Windows computers running DPM experience slow OS startup + slow 1st time logons + event log spam et al caused by the accumulation of no-longer-in-play snapshots accumulating in the \storage section of the registry.
B 2777245 SBSL: OS: Registry bloat delays boot and logon performance Known contributors for registry bloat including Adobe coldfusion, VSS snapshots including DPM backups,
KB 2498915: How to Compress "Bloated" Registry HivesCY 2011 era article that uses WINPE to load offline registry files in REGEDIT.
KB 2844430 How to compress bloated software hive 2GB after install of Microsoft SQL server 2012 SP1  Contains cleanup script. see KB 2498915 + KB 2793634
KB 2845220 Insufficient system resources exist to complete the requested service  triggered by AQL bug that causes registry bloat