The IT Handbook

← All cheat sheets

Windows

Windows repair and policy

These are common Level 1 tasks on Windows. The first two need an elevated prompt, which means Command Prompt or PowerShell run as administrator.

QuestionCommandWhat a good result looks like
Repair protected system filessfc /scannowReports no integrity violations, or that it repaired files. If it cannot repair them, run the next command and then this one again.
Repair the Windows imageDISM /Online /Cleanup-Image /RestoreHealthEnds with a message that the restore operation completed successfully. It can take a while.
Refresh Group Policy nowgpupdate /forceReports that computer policy and user policy updated successfully.
See which policies appliedgpresult /rLists the policy objects applied to the computer and to the user.