Disable SCCM Automatic Client Remediation during Windows 10 In-Place Upgrades

I ran into an issue the other day during a W10 1703 to 1709 in-place upgrade where the upgrade task sequence bombed after Windows setup had completed. The OS had upgraded successfully to 1709 and SetupDiag also reported all was well in that area, however the remainder of the task sequence never ran, not a single-step post the upgrade task, so the device was missing some post-setup customisations.

Analysis

Analysing the SCCM client logs on the local machine this is what I saw:

20/07/2018 09:20:xx AM – (execmgr.log) Windows 1709 upgrade TS started
20/07/2018 09:41:xx AM – (smsts.log) Windows 1709 upgrade Windows setup.exe completes and initiates reboot of system to complete upgrade
20/07/2018 09:59:xx AM – (ccmsetup.log) CCM setup starts a re-install of 1802 client, stopping CCMExec and un-registering components
20/07/2018 10:00:20 AM – (smsts.log) Windows 1709 upgrade starts task sequence initialization to resume upgrade process
20/07/2018 10:00:21 AM – (smsts.log) Windows 1709 upgrade error compiling SCCM policy to WMI. WMI error 0x8004108A (User attempted to register a provider instance but the COM server for the provider instance was unloaded) https://docs.microsoft.com/en-us/windows/desktop/wmisdk/wmi-error-constants
20/07/2018 10:00:22 AM – (smsts.log) Windows 1709 upgrade error starting CCMExec service. System error 0x80004005
20/07/2018 10:01:12 AM – (ccmsetup.log) CCM setup starts copying new files and registering components
20/07/2018 10:02:11 AM – (ccmsetup.log) CCM setup starts installing services
20/07/2018 10:02:24 AM – (ccmsetup.log) CCM setup starts services
20/07/2018 10:02:28 AM – (ccmsetup.log) CCM setup complete

Cause

The red text above is where things go wrong, the SCCM client starts to re-install itself during the in-place upgrade. If we look at the ccmsetup.log to see what triggered that, the command line gives us the clue:

Ccmsetup command line: “C:\WINDOWS\ccmsetup\cache\ccmsetup.exe” /remediate:client  /log:”C:\Windows\CCM\logs\repair-msi-B7D3A842-E826-4542-B39B-1D883264B279.log”

The red text shows us it is an Automatic Client Remediation repair. This feature obviously does not care if anything else is running and just happened to trigger during the upgrade and broke the task sequence execution.

Fix

If you use Automatic Client Remediation, add the following registry key in your in-place upgrade task sequence to change its behavior to Notify Only. This will ensure that it does not attempt a repair during the upgrade process.

reg.exe add “HKLM\SOFTWARE\Microsoft\CCM\CcmEval” /v NotifyOnly /t REG_SZ /d “TRUE” /f /reg:64

https://docs.microsoft.com/en-us/sccm/core/clients/deploy/configure-client-status

-Colin

4 thoughts on “Disable SCCM Automatic Client Remediation during Windows 10 In-Place Upgrades

  1. This shouldn’t happen because the client is disabled from the Upgrade Operating System task all the way up to the point that the In-Place Upgrade completes and the Task Sequence remediates the client. If your client is trying to remediate itself before this, there is something else involved that is re-enabling the client after the Upgrade Operating System task disables it. Look for scheduled tasks or client health type of scripts. You can confirm whether or not the client (CCMEXEC) was disabled during the In-Place Upgrade by looking at the setupact.log. If the start up type for CCMEXEC is 2 (auto start) vs 4 (disabled) in that log, then there is something on that PC that is re-enabling the client.

    Like

  2. I had this same issue with trying to go from Windows 7 to Windows 10 1809. I had a lot of the errors above, as well as 8004100e, in the logs. The reghack above did not work for me. The upgrade ran until “Updating” was at 100%. The machines would hang at this point for an hour.

    After an hour, Win 10 1809 would pop up. I found that the SCCM agent, as well as WMI, were completely hosed. Running a repair on the SCCM agent did nothing. I had to do a full removal of the SCCM client, and repair of WMI.

    The issue turned out to be the fact that my company upgraded WMF to version 5.1 on all our Win 7 machines prior to my starting there.

    The below MS article was the fix:

    https://support.microsoft.com/en-us/help/4470553/configuration-manager-in-place-upgrade-task-sequence-does-not-continue

    Like

Leave a reply to Chet Pacucci Cancel reply