1

I'm executing Dism.exe /online /Cleanup-Image /StartComponentCleanup as a part of regular maintenance.

It's working fine on Windows 2012r2, but it fails from time to time on Windows 2016.

Here's screenshot with error details:

Any ideas how it can be fixed?

Thanks in advance!

example

kagarlickij
  • 7,327
  • 10
  • 36
  • 71

2 Answers2

1

I have seen exactly this error too with a fresh Windows Server 2016 ISO (January build) install, updates from August 2017 and then following the Dism sequence in the question (the presence of /ResetBase doesn't change the outcome). Other versions of Windows (Server 2012 R2, Windows 10) do not generate this problem.

Someone in the Microsoft forums also says that doing Dism.exe /online /Cleanup-Image /StartComponentCleanup /ResetBase on Server 2016 resulted in HRESULT = 0x80070002 - ERROR_FILE_NOT_FOUND in the CBS.log but sadly the post went unanswered. My experience found the same error in the same log.

In both the MS forum case and my own, running Dism for a second time results in the progress only getting to 20% despite it saying that the operation was successful. Running sfc /scannow doesn't resolve this problem.

The suggestion on the forum is that there is an inherent bug in Windows Server 2016 and I have to agree - this looks like something only Microsoft can look into and seems highly reproducible.

Anon
  • 339
  • 5
  • 8
0

Regarding DISM appearing to freeze at 20% but being successful, sometimes you need to hit Enter a couple times to refresh the screen and you will see it leap ahead. It's not really crashed. I've even looked at the two DISM entries in Task Manager and they showed 0% CPU and yet, hit enter a few times and it shows up as running or done.