Error with code 80041002 during SCCM client installation

Software Center client was auto uninstalling post installation completion and it was returning error with code 80041002 during SCCM client installation.

In the \\host\windows\ccmsetup\logs\ccmsetup.log file it was returning –

MSI: Setup was unable to compile the file DiscoveryStatus.mof
The error code is 80041002	ccmsetup	28/08/2024 12:03:52 PM	14516 (0x38B4)

MSI: Action 12:03:53: Rollback. Rolling back action:	ccmsetup	28/08/2024 12:03:53 PM	14516 (0x38B4)

File C:\WINDOWS\ccmsetup\{EBC2C590-6BD4-4468-8F10-5823837E35D0}\client.msi installation failed. Error text: ExitCode: 1603

Action: CcmRegisterWmiMofFile.

ErrorMessages:
Setup was unable to compile the file DiscoveryStatus.mof
The error code is 80041002
	ccmsetup	28/08/2024 12:04:36 PM	14516 (0x38B4)

Next retry in 120 minute(s)...	ccmsetup	28/08/2024 12:04:36 PM	14516 (0x38B4)

Follow steps below to resolve the “Setup was unable to compile the file DiscoveryStatus.mof” error with code 80041002 during SCCM client installation:

  1. This is a common error that occurs during Configuration Manager client installation or upgrade.
  2. The solution involves compiling the ExtendedStatus.mof file:
    • Open an elevated command prompt (run as administrator)
    • Navigate to: C:\Program Files\Microsoft Policy Platform
    • Run the following command:
mofcomp ExtendedStatus.mof
c:\Program Files\Microsoft Policy Platform>mofcomp ExtendedStatus.mof
mofcomp ExtendedStatus.mof
Microsoft (R) MOF Compiler Version 10.0.19041.3758
Copyright (c) Microsoft Corp. 1997-2006. All rights reserved.
Parsing MOF file: ExtendedStatus.mof
MOF file has been successfully parsed
Storing data in the repository…
Done!
  1. After running this command, retry the SCCM client installation.
c:\Windows\ccmsetup\cache>ccmsetup.exe /mp:PrimarySite.internal.domain.org.au SMSSITECODE=P01
  1. If the “Microsoft Policy Platform” folder is missing, you may need to install the microsoftpolicyplatformsetup.msi, which is included in the ccmsetup client install package (in the x64 subfolder).
  2. In some cases, you may need to uninstall the existing SCCM client, reboot the machine, and then attempt the reinstallation after performing the mofcomp step.
  3. If issues persist, you can try running a system file check:
sfc /scannow
  1. For manual client push installation, you can use the following command line (adjust parameters as needed):
ccmsetup.exe SMSMP=<your_MP> SMSSITECODE=<your_site_code>

This solution has been tested to work across multiple versions of SCCM/Configuration Manager, including SCCM 2012, 1810, 2309 and newer versions.

One comment

  1. […] Using these steps, you should be able to identify and resolve the cause of the 0x40010004 error in SCCM. If the issue persists, further investigation into the specific environment and configuration might be necessary. In my case, the app deployment was throwing this exception due to corrupt Software Center on the endpoint. Refer to Error with code 80041002 during SCCM client installation. […]

Leave a Reply

Your email address will not be published. Required fields are marked *