Two steps about Client Upgrade in Post-Installation part stuck in In progress

Two steps about Client Upgrade in Post-Installation part stuck in In progress

ISSUE

Two steps about Client Upgrade in Post-Installation part stuck in In progress during an upgrade from 1909 to 2006

These two steps are : 

  1. Updating Client folder on Site Server 

  2. Updating Configuration Manager Client Package 

hman.log

Loaded client upgrade settings from DB successfully. FullClientPackageID=SG100002, StagingClientPackageID=SG100017, ClientUpgradePackageID=SG100003, PilotingUpgradePackageID=SG10074E, ClientUpgradeAdvertisementID=SG120000, ClientPilotingAdvertisementID=SG120BFF
Both UpgradeAdvertisementID and PilotingAdvertisementID existed in the output of ClientDeploymentSettings, while, the advertisementID 'SG120000' couldn't be found in table ProgramOffers, that's why these two steps stuck there, and keep being retried. 
    SQL>>>select PkgID,PkgProgram,CollectionID,SourceSite,OfferName,OfferComment,Hierarchy,AvailableSched,UnavailableSched,MandatorySched,PresentTime,ExpirationTime,TimeEnableFlag,OfferFlags,DeviceFlags,RemoteClientFlags,Priority,AssignmentID,MandatoryCountdown,SourceLocaleID,LastModificationTime,OfferTypeID,ISVString,AdditionalProperties from ProgramOffers where OfferID = 'SG120000' and Action <> 3
SQL>>>>> Done.
ERROR: Failed to get the advertisement object for advertisement SG120000.
ERROR: Failed to add a new mandatory schedule to the client upgrade advertisement SG120000. Will continue on next cycle.
WARN: It fails to process the client content in the update package A200E842-5CB5-4BD3-AB77-2999B59721AE. Will retry in next cycle.

Solution

  1. Go to the top-level site 
  2. Navigate into <ConfigMgr>\inboxes\hman.box 
  3. Create an empty CliUpg.acu file in <ConfigMgr>\inboxes\hman.box 
  4. Restart SMS_EXECUTIVE service from services.msc panel 

SCCM 2107 upgrade package stuck in Downloading state

SCCM 2107 upgrade package stuck in Downloading state

Issue

SCCM 2107 upgrade package stuck in Downloading state

Errors in dmpdownloader.log

SMS_DMP_DOWNLOADER    15060 (0x3ad4)    Error in verifying the trust of file 'E:\Program Files\Microsoft Configuration Manager\EasySetupPayload\42e1cf6e-95a1-4a8d-96ad-311e6247b3fb.cab'.
SMS_DMP_DOWNLOADER    15060 (0x3ad4)    WARNING: Failed to call IsFileTrusted~~

What I observed is that 42e1cf6e-95a1-4a8d-96ad-311e6247b3fb.cab was downloaded but its size is actually smaller than its true size. This led to the hash verification failure as seen in the log above.

Solution

Enable those address internet access for service connection point – Internet access requirements – Configuration Manager | Microsoft Docs

Management point role installation fails on the secondary site with “Child process exited with non-zero code 102”

Management point role installation fails on the secondary site with “Child process exited with non-zero code 102”

Issue

After an upgrade from 2010 to 2103, the management point role installation on a secondary site keeps failing with the following exceptions in sitecom.log

08-31-2021 12:40:37.867 SMS_SITE_COMPONENT_MANAGER 4408 (0x1138) Installed service SMS_SERVER_BOOTSTRAP_STLCANSCCM.
08-31-2021 12:40:37.868 SMS_SITE_COMPONENT_MANAGER 4408 (0x1138) Starting service SMS_SERVER_BOOTSTRAP_STLCANSCCM with command-line arguments "SWK D:\Program Files\Microsoft Configuration Manager /install D:\Program Files\Microsoft Configuration Manager\bin\x64\rolesetup.exe SMSBGB "…
08-31-2021 12:42:17.015 SMS_SITE_COMPONENT_MANAGER 4408 (0x1138) Execution of "D:\Program Files\Microsoft Configuration Manager\bin\x64\rolesetup.exe /install /siteserver:CONTOSO.LOCAL.LAB" on server CONTOSO.LOCAL.LAB failed: Child process exited with non-zero code 102.
08-31-2021 12:42:17.016 SMS_SITE_COMPONENT_MANAGER 4408 (0x1138) bgbisapi.msi could not install correctly on server CONTOSO.LOCAL.LAB.
08-31-2021 12:42:17.016 SMS_SITE_COMPONENT_MANAGER 4408 (0x1138) Bootstrap operation failed.

102 here means “The semaphore is set and cannot be closed“. However, it is hard to figure out what that refers to.

Error Code: 0x66 (102)
Error Name: ERROR_SEM_IS_SET
Error Source: Windows
Error Message: The semaphore is set and cannot be closed.

Wikipedia explains it this way –

A semaphore, in computer science, is a protected variable (an entity storing a value) or abstract data type (an entity grouping several variables that may or may not be numerical) which constitutes the classic method for restricting access to shared resources, such as shared memory, in a multiprogramming environment (a system where several programs may be executing, or taking turns to execute, at once). Semaphores exist in many variants, though usually the term refers to a counting semaphore, since a binary semaphore is better known as a mutex. A counting semaphore is a counter for a set of available resources, rather than a locked/unlocked flag of a single resource. It was invented by Edsger Dijkstra. Semaphores are the classic solution to preventing race conditions in the dining philosophers problem, although they do not prevent resource deadlocks.

Capturing a ProcMon, I found the process where 102 was thrown and launched the process tree, where the unlodctr.exe caught my eye. This command “D:\Program Files\Microsoft Configuration Manager\bin\x64\rolesetup.exe /install /siteserver:CONTOSO.LOCAL.LAB” was actually calling “C:\Windows\system32\unlodctr.exe” “sms notification server” to unload the performance counters for sms notification server. But it failed.

The procmon content is as below –

12:42:15.2625967 8/31/2021 12:42:15 rolesetup.exe 5516 Process Exit SUCCESS Exit Status: 102, User Time: 0.0937500 seconds, Kernel Time: 0.2812500 seconds, Private Bytes: 2,666,496, Peak Private Bytes: 2,916,352, Working Set: 13,082,624, Peak Working Set: 13,430,784

SOLUTION

  1. Open an elevated CMD
  2. Run
    1. cd \windows\system32
    2. lodctr /R
    3. Restart the secondary site

If the above does not work, you can further try the following:

1. Uninstall the MP role from SCCM console
2. Delete CCM name instance from WMI
  a. Open WBEMTest and connect to root
  b. Click enum classes and choose "Recursive" then click okay
  c. Under Query Result go to _NAMESPACE and double click it.
  d. Hit the "Instances" button on the right hand side.
  e. Then highlight the _NAMESPACE.name="ccm" value and click delete to remove it.
3. Install MP again.

References

Upgrade to Windows 20H2 failed via Feature Update

Upgrade to Windows 20H2 failed via Feature Update

One of my customers called me saying that NONE of their computers failed to upgrade to Windows 20H2. The upgrade rolled back in the end.

06-29-2021 15:18:51.000 MOUPG CDlpTask::Cancel(982): Result = 0xC1800104
06-29-2021 15:18:51.000 MOUPG CDlpTask::Cancel(982): Result = 0xC1800104
06-29-2021 15:18:51.000 MOUPG CDlpTask::Cancel(982): Result = 0xC1800104
06-29-2021 15:18:51.000 MOUPG CDlpTask::Cancel(985): Result = 0xC1800109
06-29-2021 15:18:51.000 MOUPG CDlpTask::Cancel(982): Result = 0xC1800104
06-29-2021 15:18:51.000 MOUPG CSetupManager::Execute(295): Result = 0x800704C7
06-29-2021 15:18:51.000 MOUPG CSetupHost::Execute(433): Result = 0x800704C7
06-29-2021 15:20:21.000 MOUPG CSetupHost::ExecuteDiagnosticAnalysis(1567): Result = 0x800705B4

0x800704C7 refers to –

Error Code: 0x4C7 (1223)
Error Name: ERROR_CANCELLED
Error Source: Windows
Error Message: The operation was canceled by the user.

0x800705B4 refers to –

Error Code: 0x5B4 (1460)
Error Name: ERROR_TIMEOUT
Error Source: Windows
Error Message: This operation returned because the timeout period expired.

WUHandler.log has the following:

06-29-2021 13:06:45.036 WUAHandler 11584 (0x2d40) Installation job encountered some failures. Job Result = 0x80240022.
06-29-2021 13:06:45.036 WUAHandler 11584 (0x2d40) Update 1 (d0d36236-5587-494f-85d5-26a519ea7f99) finished installing (0x8024200d), Reboot Required? No

Error Code: 0x8024200D (2149851149)
Error Name: WU_E_UH_NEEDANOTHERDOWNLOAD
Error Source: Windows Update Agent
Error Message: The update handler did not install the update because it needs to be downloaded again.

This seems to be an issue of update max run time and incomplete update content. So, I asked the customer to increase Maximum Run Time from 60 to 600 minutes (Figure 1), then remove the update content from the distribution point and re-download the update and redistribute the update content to the distribution point. In addition, to make sure the client computer can have the newly downloaded update content, I asked the customer to clear the SCCM client cache (see below).

$resman= New-Object -ComObject "UIResource.UIResourceMgr"
$cacheInfo=$resman.GetCacheInfo()
$cacheinfo.GetCacheElements()  | foreach {$cacheInfo.DeleteCacheElement($_.CacheElementID)}

Figure 1

However, that did not help. The latest WindowsUpdate.log shows the following messages which suggested the same error as the ones we saw in WHandler.log.

01-01-0001 00:00:00.000 #54#[0]3240.1078::07/02/21-14:43:01.5506006 [WUTraceLogging] [DownloadManager] Info=Preparing update for install, updateId = 3BFC714E-F079-46D3-ABFB-E2EA6E85344A.201.
01-01-0001 00:00:00.000 #54#[0]00F0.289C::07/02/21-14:43:01.5512527 [WUTraceLogging] [Handler] Info=* START * Windows Setup Install
01-01-0001 00:00:00.000 #54#[0]00F0.289C::07/02/21-14:43:01.5512565 [WUTraceLogging] [Handler] Info=Updates to install = 1
01-01-0001 00:00:00.000 #54#[0]00F0.289C::07/02/21-14:43:01.6494766 [WUTraceLogging] [Handler] Info=Starting Windows Setup with command line = "C:\WINDOWS\SoftwareDistribution\Download\ca39e21ca430b617fe8e922b0048000a\WindowsUpdateBox.exe" /ClassId 98424e9a-a4e3-4475-a925-03d57ce52589 /ReportId {3BFC714E-F079-46D3-ABFB-E2EA6E85344A}.201 /PreDownload /Update /ClientId 37148ea8-45b8-4d3a-9be6-e46e323fd3d7 /CorrelationVector X83IOjjys0SOaxMx.7.0.0.3
01-01-0001 00:00:00.000 #54#[0]00F0.289C::07/02/21-14:44:26.9527610 [WUTraceLogging] [Handler] Info=FAILED [8024200D] Method failed [CUHWinSetupHandler::Install:762]
01-01-0001 00:00:00.000 #54#[0]00F0.289C::07/02/21-14:44:26.9527636 [WUTraceLogging] [Handler] Info=* END * Windows Setup Install
01-01-0001 00:00:00.000 #54#[0]3240.1078::07/02/21-14:44:26.9534108 [WUTraceLogging] [DownloadManager] Info=Install failed because the update 3BFC714E-F079-46D3-ABFB-E2EA6E85344A.201 was not complete; mark update as not downloaded.
01-01-0001 00:00:00.000 #54#[0]3240.1078::07/02/21-14:44:26.9537975 [WUTraceLogging] [Agent] Info=FAILED [8024200D] Method failed [CAgentUpdateManager::InstallUpdate:11739]
01-01-0001 00:00:00.000 #54#[0]2620.0A24::07/02/21-14:44:26.9616399 [WUTraceLogging] [ComApi] Info=Install call complete (succeeded = 0, succeeded with errors = 0, failed = 1, cancelled = 0, unaccounted = 0
01-01-0001 00:00:00.000 #54#[0]2620.0A24::07/02/21-14:44:26.9617139 [WUTraceLogging] [ComApi] Info=Reboot required = False
01-01-0001 00:00:00.000 #54#[0]2620.0A24::07/02/21-14:44:26.9617168 [WUTraceLogging] [ComApi] Info=Exit code = 0x00000000; Call error code = 0x80240022
01-01-0001 00:00:00.000 #54#[0]2620.0A24::07/02/21-14:44:26.9617184 [WUTraceLogging] [ComApi] Info=* END * Install ClientId = CcmExec
01-01-0001 00:00:00.000 #54#[0]3240.0E98::07/02/21-14:44:26.9617693 [WUTraceLogging] [Agent] Info=WU client calls back to install call {35D9C0A7-1B48-4E84-84C3-81920C7D9F62} with code Call complete and error 0
01-01-0001 00:00:00.000 #54#[0]2620.1A94::07/02/21-14:44:26.9619270 [WUTraceLogging] [ComApi] Info=Install call complete (succeeded = 0, succeeded with errors = 0, failed = 1, cancelled = 0, unaccounted = 0

But the UpdateHandler.log indicates the update has been successfully downloaded onto the client –

07-02-2021 14:26:52.922 UpdatesHandler 10804 (0x2a34) Bundle update (d0d36236-5587-494f-85d5-26a519ea7f99) is requesting download from child updates for action (INSTALL)
07-02-2021 14:26:52.938 UpdatesHandler 10804 (0x2a34) FullAndExpress file does not exist for UpdateID [3bfc714e-f079-46d3-abfb-e2ea6e85344a]. Creating new file [C:\WINDOWS\CCM\Temp\Delta_3bfc714e-f079-46d3-abfb-e2ea6e85344a]
07-02-2021 14:26:52.939 UpdatesHandler 10804 (0x2a34) FullAndExpress file for UpdateID [3bfc714e-f079-46d3-abfb-e2ea6e85344a] created
07-02-2021 14:26:52.941 UpdatesHandler 10804 (0x2a34) CUpdate::CheckLocations - Checking locations on action (INSTALL) for Update (3bfc714e-f079-46d3-abfb-e2ea6e85344a)
07-02-2021 14:26:52.941 UpdatesHandler 16980 (0x4254) Ignoring update id (d0d36236-5587-494f-85d5-26a519ea7f99) state (DOWNLOAD_READY) change in job state (2)
07-02-2021 14:26:53.394 UpdatesHandler 10804 (0x2a34) Starting download on action (INSTALL) for Update (3bfc714e-f079-46d3-abfb-e2ea6e85344a)
07-02-2021 14:26:53.474 UpdatesHandler 10804 (0x2a34) FullAndExpress file already exists for UpdateID [3bfc714e-f079-46d3-abfb-e2ea6e85344a]. File [C:\WINDOWS\CCM\Temp\Delta_3bfc714e-f079-46d3-abfb-e2ea6e85344a]
07-02-2021 14:42:26.646 UpdatesHandler 13396 (0x3454) ContentAvailable notification received from CAS.
07-02-2021 14:42:26.646 UpdatesHandler 13396 (0x3454) Contents downloaded successfully for Update (3bfc714e-f079-46d3-abfb-e2ea6e85344a).
07-02-2021 14:42:26.655 UpdatesHandler 7260 (0x1c5c) StateCore - bundle update (d0d36236-5587-494f-85d5-26a519ea7f99) state changed from (WAIT_CONTENTS) to (EXECUTE_READY) as child update state changed
07-02-2021 14:42:26.659 UpdatesHandler 7260 (0x1c5c) Download completed for the job ({B75A544F-92B0-43AA-A0EE-B24ED6E7CC6C}).

What is weird is that UpdateHandler.log shows some other messages just two minutes later that another download is needed but only to find the update is already there. And this process repeated.

07-02-2021 14:44:26.963 UpdatesHandler 6980 (0x1b44) WSUS update (d0d36236-5587-494f-85d5-26a519ea7f99) installation result = 0x8024200d, Reboot State = NoReboot
07-02-2021 14:44:26.963 UpdatesHandler 6980 (0x1b44) Update (d0d36236-5587-494f-85d5-26a519ea7f99) execution return with need another download
07-02-2021 14:44:27.003 UpdatesHandler 18284 (0x476c) Update enforcement need another download. Begin fast retry of download and install…
07-02-2021 14:44:27.003 UpdatesHandler 18284 (0x476c) Initiating download for the job ({B75A544F-92B0-43AA-A0EE-B24ED6E7CC6C}).
07-02-2021 14:44:27.003 UpdatesHandler 18284 (0x476c) Check contents availability.
07-02-2021 14:44:27.034 UpdatesHandler 18284 (0x476c) Bundle update (d0d36236-5587-494f-85d5-26a519ea7f99) is requesting download from child updates for action (INSTALL)
07-02-2021 14:44:27.052 UpdatesHandler 18284 (0x476c) FullAndExpress file already exists for UpdateID [3bfc714e-f079-46d3-abfb-e2ea6e85344a]. File [C:\WINDOWS\CCM\Temp\Delta_3bfc714e-f079-46d3-abfb-e2ea6e85344a]
07-02-2021 14:44:27.053 UpdatesHandler 18284 (0x476c) CUpdate::CheckLocations - Checking locations on action (INSTALL) for Update (3bfc714e-f079-46d3-abfb-e2ea6e85344a)
07-02-2021 14:44:27.572 UpdatesHandler 18284 (0x476c) Starting download on action (INSTALL) for Update (3bfc714e-f079-46d3-abfb-e2ea6e85344a)
07-02-2021 14:44:27.594 UpdatesHandler 18284 (0x476c) Contents already available.
07-02-2021 14:44:27.600 UpdatesHandler 18284 (0x476c) FullAndExpress file already exists for UpdateID [3bfc714e-f079-46d3-abfb-e2ea6e85344a]. File [C:\WINDOWS\CCM\Temp\Delta_3bfc714e-f079-46d3-abfb-e2ea6e85344a]
07-02-2021 14:44:27.620 UpdatesHandler 18284 (0x476c) StateCore - bundle update (d0d36236-5587-494f-85d5-26a519ea7f99) state changed from (WAIT_CONTENTS) to (EXECUTE_READY) as child update state changed
07-02-2021 14:44:27.623 UpdatesHandler 14556 (0x38dc) Download completed for the job ({B75A544F-92B0-43AA-A0EE-B24ED6E7CC6C}).

I asked the customer what the client computers have in common. A certain Antivirus software, he replied. Oh, that is not something we can ignore in this case. You might have guessed the final solution. Right, the issue was gone after we removed that antivirus software.

Using task sequence to upgrade computers to 1909 failed with exit code hexadecimal 0x80070032

Using task sequence to upgrade computers to 1909 failed with exit code hexadecimal 0x80070032

Sometimes you may encounter upgrade to 1909 failure via task sequence with the following exceptions in smsts.log –

OSDUpgradeWindows 15052 (0x3acc) Windows Setup completed with exit code hexadecimal 0x80070032 (decimal 2147942450)
OSDUpgradeWindows 15052 (0x3acc) Saving exit code of Windows upgrade - hexadecimal 0x80070032 (decimal 2147942450) - to Task sequence environment variable '_SMSTSOSUpgradeActionReturnCode', as decimal string
OSDUpgradeWindows 15052 (0x3acc) Windows Setup failed with hexadecimal exit code 0x80070032 (decimal 2147942450). To identify the type of issue, lookup it against the table of known values of Windows Setup errors online.
OSDUpgradeWindows 15052 (0x3acc) Failing this task sequence step
OSDUpgradeWindows 15052 (0x3acc) upgrade.Run(), HRESULT=80004005 (upgradewindows.cpp,1727)
OSDUpgradeWindows 15052 (0x3acc) Exiting with code 0x80004005
TSManager 15264 (0x3ba0) Process completed with exit code 2147500037
TSManager 15264 (0x3ba0) Failed to run the action: Upgrade Operating System - zh-CN OS Lang only. Error -2147467259

0x80070032 refers to –

Error Code: 0x32 (50)
Error Name: ERROR_NOT_SUPPORTED
Error Source: Windows
Error Message: The request is not supported.

The setuperr.log contains the following –

Info MOUPG Mapped Global progress: [95%]
……
Warning VdsPlatform::IsAvailable: Couldn't create VDS loader instance (0x80080005)
Warning WMI Helper Library: Wmi::OpenNamespace: Too late to initialize COM security (0x80010119)
Error WMI Helper Library: Getting WMI Uint16 property DriveLetter: unexpected VARIANT type 1
Error Failed to read MSFT_Volume.DriveLetter, although the property exists; unexpected type? (0x8007070c)
Warning SmPlatform::IsAvailable: Couldn't initialize SM API (0x8007070c)
Error SP CSetupPlatform::Initialize: Disk provisioning is not available; hr = 0x80070032
Error SP ResurrectSetupPlatform: Cannot initialize deserialized setup platform. Error: 0x80070032

If you see the same messages, uninstall LanDesk from the client computer and try again.

Feature Update 1909 failed with 0xC1900208

Feature Update 1909 failed with 0xC1900208

The customer was trying to upgrade from 1703 to 1909 via Feature Update but came across the following exception.

0xC1900208 ” means – The system does not pass the compat scan to install the update.

setuperr.log has the following –

06-07-2021 07:34:12.000 MOUPG CDlpTask::CheckUserInterruptEx(3060): Result = 0x800704D3
06-07-2021 07:34:12.000 MOUPG CDlpTask::CheckUserInterrupt(3112): Result = 0x800704D3
06-07-2021 07:34:15.000 MOUPG CSetupManager::ExecuteInstallMode(822): Result = 0xC1900208
06-07-2021 07:34:15.000 MOUPG CSetupManager::ExecuteDownlevelMode(392): Result = 0xC1900208
06-07-2021 07:34:34.000 MOUPG CSetupManager::Execute(284): Result = 0xC1900208
06-07-2021 07:34:34.000 MOUPG CSetupHost::Execute(420): Result = 0xC1900208

But what was blocking the upgrade?

An easy way is to launch setup.exe from the C:\$WINDOWS.~BT directory. Afer you the first screens, the setup will warn you about possible incompatible apps.

Alternatively, you can also refer to the C:\$WINDOWS.~BT\Sources\Panther\CompatData[datetime].xml, eg. CompatData_2021_06_07_07_34_10_3_006f0018.xml. There can usually be multiple Compatdata.xml files. But the most recent one should contain the information you desire. In my example, it is the VMware Player that brought the issue.

CompatData xml log shows an incompatible software that was blocking the upgrade.

Solution is –

  1. Uninstall the incompatible software, in my case it is VMware Player
  2. Clear SCCM Cache by opening PowerShell as Admin and run:
    $resman= New-Object -ComObject "UIResource.UIResourceMgr"
    $cacheInfo=$resman.GetCacheInfo()
    $cacheinfo.GetCacheElements() | foreach {$cacheInfo.DeleteCacheElement($_.CacheElementID)}
  3. Remove the content of C:\WINDOWS\SoftwareDistribution\Download folder.
  4. Note that you may need to stop the Windows Update service (wuauserv) before renaming or deleting the content in that directory. To stop that service, open PowerShell as Admin and run: Stop-Service wuauserv
  5. Restart that service after deleting the content: Start-Service wuauserv
  6. Remove the C:\$WINDOWS.~BT folder (Note that this folder is hidden)
  7. Restart the computer
  8. Try a Software Update Deployment Evaluation Cycle and Software Update Scan Cycle
  9. Wait a couple of minute for the scan to complete and retry the deployment
Design a site like this with WordPress.com
Get started