[SOLVED] DISM - Failed while processing command cleanup-image. - CPackageManagerCLIHandler::ExecuteCmdLine(hr:0x80070002)

Joined
Oct 21, 2021
Posts
9
Good morning, I'm trying to run the accumulative windows 10 update for October, it's giving the error 0x80070002, running the command DISM.exe /Online /Cleanup-Image /RestoreHealth displays error 2. In the log dism.log displays the message Failed while processing command cleanup-image. - CPackageManagerCLIHandler::ExecuteCmdLine(hr:0x80070002)

I used FRST.exe to gather more data, it's attached.

Could you help me please?

Yours sincerely,

Andrew
 

Attachments

Hi Andrew,

Error 0x80070002 indicates that an expected package or system files are missing from your machine.

Please would you be able to run through the WU Posting Instructions so we can get a more detailed look at your system?
Windows Update Forum Posting Instructions


Thanks,
Will
 
Hi Andrew,

Some of the registry keys are being flagged as missing or corrupted. Lets take a look at the COMPONENTS registry hive.

Retrieve the Components Hive
  1. Navigate to C:\Windows\System32\Config and locate the COMPONENTS file
  2. Please copy the COMPONENTS file to your desktop
    Note: If you receive an error that this file is in-use, simply reboot your computer and try again
  3. Right-click on this file on your Desktop and select Send To...Compressed (zipped) folder. This will create a file named COMPONENTS.ZIP on your Desktop
  4. Upload the file directly to Sysnative. If the file is too large to upload to the forum please share the file using a service like Dropbox, OneDrive, Google Drive, or upload to www.sendspace.com and just provide the link for the file here.
 
Hi Andrew,

Thanks for this.

There's a registry key flagged in the CBS log as missing. We'll replace the missing registry key now, but there may be other corruptions to fix.


Step 1 - Replace Components Hive Manually

Warning:
this fix is specific to the user in this thread. No one else should follow these instructions as it may cause more harm than good. If you are after assistance, please start a thread of your own.

  1. Download Components Fix.ZIP and save to your desktop.
  2. Right-click on it and select Extract all.... Make sure the "Show extracted files when complete" is checked and click Extract.
  3. Now we have the COMPONENTS file that we will be using to replace your current one.
  4. Navigate to C:\Windows\System32\config
  5. Right-click on the current COMPONENTS file and select rename. Rename it to COMPONENTS.bad.
    Note: If you get an error that the file is in use, reboot your computer and then try again.
  6. Take the file from the Components folder on your desktop and paste it into C:\Windows\System32\config
Step 2: Please run another DISM after this and provide the latest CBS Folder so that we can assess what is left to fix.
 

Attachments

Hey Andrew,

Could you navigate to your Windows Update settings, and then take a screenshot of the Update History section?

  1. Click Start -> Search for "Windows Update" -> Click Windows Update Settings
  2. Click Update History
  3. Take a screenshot using the Snipping Tool or screenshot tool of your choice, and post the results here.

We'll try and manually install any failed updates afterwards. The latest CBS log flags some new errors - unfortunately it flags these one at a time, so it's difficult to detect how many registry keys may be missing or corrupted.
 
Hi Will,

Attached is the image with the history of updates made on that computer.

Thanks,

Andrew
 

Attachments

  • WindowsUpdateHistory.PNG
    WindowsUpdateHistory.PNG
    98.8 KB · Views: 8
I Will,
Sorry for the delay in responding, but running the update manually the error still persists. Attached is the CBS logs folder.

Yours sincerely,

Andrew
 

Attachments

Hi Andrew,

Thanks for posting this - I'm currently reviewing the latest log files and will post an update here soon.

Thanks,
Will
 
Hi Andrew,

Reviewing the logs, we still have some similar corruptions to the registry fix we carried out in post #6. The good news is that we have made progress, and the previous registry fix was successful, the bad news is that we're not able to judge at this stage how many registry fixes will be required.

We're happy to continue fixing the machine, but please be aware that sometimes this can take a large amount of time, and we're not able to estimate this up front. For complex fixes this can take several weeks or longer of back and forth fixes. As an alternative, you could try waiting until the next update release to see if the issue can be automatically resolved, or if this is very time sensitive then you could carry out a repair installation / reinstall Windows.

If you'd like to proceed, please retrieve the latest version of the COMPONETS hive. We'll apply as many registry fixes to this as possible to speed up the process.

Retrieve the Components Hive
  1. Navigate to C:\Windows\System32\Config and locate the COMPONENTS file
  2. Please copy the COMPONENTS file to your desktop
    Note: If you receive an error that this file is in-use, simply reboot your computer and try again
  3. Right-click on this file on your Desktop and select Send To...Compressed (zipped) folder. This will create a file named COMPONENTS.ZIP on your Desktop
  4. Upload the file directly to Sysnative. If the file is too large to upload to the forum please share the file using a service like Dropbox, OneDrive, Google Drive, or upload to www.sendspace.com and just provide the link for the file here.
 
Hi Will, thanks for replying.

In the month of November, microsoft will release the 21H2 version of windows 10 pro, will it probably fix this problem?

If so, I'll wait to run it, if not, I'll try to format the computer.

But I'm already grateful for the help.

Yours sincerely,
Andrew
 
Hey Andrew,

There's a chance the next update would fix the problem, but we do see a lot of machines here that can't be automatically fixed. You might get lucky with it, but it's hard to tell up front how likely or not that is.

For a reinstall - you can either do a repair install, or if you really want a clean start you can do a full format and reinstallation. Both will lose installed software, but the repair install will keep personal files.

We're happy to continue trying to fix the machine as well as a third option.

Thanks,
Will
 
Hi Will, how are you?

Today, I installed the KB5006738 update and it resolved the issue by not asking for the old update anymore.

Thanks for the help and anyone with the same problem as mine try to run the new update.

Yours sincerely,

Andrew
 
That's great, glad it's fixed!

Thanks for letting us know as well - I'll mark this thread as solved.
 

Has Sysnative Forums helped you? Please consider donating to help us support the site!

Back
Top