dism.exe commands in windows server 2008 R2

Mohlalefi
Mohlalefi used Ask the Experts™
on
Am I missing something with the commands below?

1. dism.exe /image: <drive letter>: \ /cleanup-image /revertpendingactions

2. sfc /scannow /offbootir= <drive letter>:\/offwindir=<drive letter>:\windows

the first command gives the message--missing servicing command.
the second command does not run successfully either.
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Business Consultant (Owner)
Most Valuable Expert 2012
Expert of the Year 2018
Commented:
On my Windows 8.1 machine, I did the following:

DISM.exe /Online /Cleanup-image /Scanhealth which took a while to run and said files could be fixed.
and then
DISM.exe /Online /Cleanup-image /Restorehealth which took another long while and fixed the files.

Then SFC ran without errors.

You might try the first command to scan and see if it produces results. I have not used the revert command you posted above.

Author

Commented:
John, where did you run the commands from ? I cannot log on to my Windows server 2008 R2, and I am running these commands from the system recovery options cmd prompt, in an attempt get bad patches off my image.
JohnBusiness Consultant (Owner)
Most Valuable Expert 2012
Expert of the Year 2018

Commented:
Hmmm, you did not mention you could not log on. I ran the commands from a command window in a running system.

The subcommands I posted are DISM commands like you are running. Try the restorehealth command to see if it run or if it produces the same error.
JohnBusiness Consultant (Owner)
Most Valuable Expert 2012
Expert of the Year 2018

Commented:
@Mohlalefi  - Thank you and I was happy to help.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial