I have many customers who have experienced the same issue deploying 64-bit Windows 7 using a 32-bit boot image. The error has not been consistent either the Apply Driver Package step fails and the DISM log file indicates that it cannot read the Software Hive from the registry or the machine blue-screen on first boot.
Rebuilding the master image has solved the problem. I have one customer who logged a case with Microsoft Support and got this solution that works great!
Thanks Ola Ahrens for sharing!!
WinPe tries compacting the offline registry and fails to commit the registry hives back to disk.
This problem only happen when you deploy windows 7 and use WinPe 5.0 or 5.1, 32 bit, to deploy the image.
Note: Sccm 2012 R2 and higher uses winpe 5.0 or higher to deploy os images.
Create a Value in WinPE
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Configuration Manager
This value has the effect that the registry hives are not compacted as long as the modified date of the hives is not older than a year.
When you intend to use the deployment longer than a year, a higher value must be chosen.