Issue:
When offline servicing a Windows 7 or 10 image in System Center Configuration Manager (SCCM) you recieve an error that it is not possible to update the image.
Reason:
The reason for this issue is that in the Registry, of the WIM file you are trying to update, the value in the SessionsPending\Excluding dword value is incorrect. The value states that a reboot is required, which is not possible for the WIM file.
Solution:
- Get the correct index number
– Open an elevated Powershell console
– Dism /Get-WimInfo /WimFile:<Path+NameOfYourWim.wim>
- Mount the WIM image using DISM.
– Dism.exe /mount-wim /wimfile:<Path+NameOfYourWim.wim> /index:1 /mountdir:<PathOfYourMountDir>
- Mount the software registry hive
– reg load HKLM\MountReg <PathOfYourMountDir>\windows\system32\config\software
- Change the registry settins
– Open RegEdit.exe
– Go to the following path: HKEY_LOCAL_MACHINE\MountReg\Microsoft\Windows\CurrentVersion\Component Based Servicing\SessionsPending
– Check if the value of the Exclusive DWORD key is 3 (this should be 0)
– Claim ownership of the SessionsPending hive
– Change permissions of the SessionsPending hive
– Change the value of the Exclusive DWORD key to 0
– Close the Registry Editor - Unmount the registry hive
– Reg unload HKLM\MountReg - Unmount the WIM image committing changes
– Dism /Unmount-Image /MountDir:<Path+NameOfYourWim.wim> /Commit
- Offline service your image in SCCM