Not to long ago we had some issues (re)deploying Windows 7 (including the baseline) on our client systems. One out of three systems failed during (re)deployment. At first we thought it was because the systems were not removed correctly from SCCM before redeployment. Further investigation told us that the deployment also failed on new systems and systems which were correctly removed from SCCM before redeployment.
- Windows 2008 R2
- Window 7
- SCCM 2007 R2
- RES Workspace Manager 2011
- App-V 4.6 SP1
CcmExec.log logged the following:
“Error unregistering notification query CcmExec“ occurs after a restart initiated by the installation of the App-V client. It seems that CcmExec (SMS Agent Host service) is having trouble to start. After a while it times out and the (re)deployment fails. The restart which is needed after the installation of the App-V client is the first restart initiated by an application after the windows installation. It could be possible that this error also occurs after other installations where a reboot is needed. Unfortunately we haven’t run tests on this, we only have one installation which needs a reboot during this phase.
By delaying the auto startup of the CcmExec service we solved the (re)deployment issues in this case. The CcmExec service will start after all other services who are configured as “Automatic” startup. Normally this is used to shorten the boot time but in this case it also helps us preventing (re)deployment failures. Right before the installation of the App-V client we added a “Run command line” to the task sequence as follows.
Type: Run Command Line
Name: Delay startup CCMexec service
Description: Delay CCMexec (SMS Host Agent) service
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\CcmExec /v DelayedAutostart /t REG_DWORD /d 00000001 /f
Before the last action of our task sequence will take place, in our case a last reboot to complete the deployment, we added the following “Run Command Line”.
Type: Run Command Line
Name: Automatic startup CCMexec service
Description: Sets CCMexec (SMS Host Agent) service on automatic start without delay
reg add HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\CcmExec /v DelayedAutostart /t REG_DWORD /d 00000000 /f
This was our solution for the (re)deployment problem we encountered and hopefully it will help some of you who experience the same problems. If you have any comment or questions you can post them down below in the comment section.