Fix Windows Update Error 800f0831

Windows Update Logo Official Microsoft 1

Windows Server 2012 R2 windows updates failing with error code 800f0831.

If any previous update is missing on the server then you will get the above error. To find the missing patch you have to check the CBS logs on the affected server and you will find the similar entries like below.

2020-04-29 04:21:03, Error                 CBS    Failed to resolve package 'Package_8_for_KB4534309~31bf3856ad364e35~amd64~~' [HRESULT = 0x800f0831 - CBS_E_STORE_CORRUPTION]
2020-04-29 04:21:03, Info                  CBS    Mark store corruption flag because of package: Package_8_for_KB4534309~31bf3856ad364e35~amd64~~ [HRESULT = 0x800f0831 - CBS_E_STORE_CORRUPTION]


Access the CBS log files on the affected computer from:


Search the CBS log files for Failed to resolve package or Mark store corruption flag and the missing KB is mentioned. Manually download and install that KB from In my case it was KB4534309.

Restart the affected computer then try running Windows Updates again normally. Repeat the solution if you encounter the same error again, a new problem KB should be reported in the logs.

Additional Suggestions

Lots of articles online suggest running the following then restarting. While these didn’t resolve my trouble you may have better success.

sfc /scannow
dism /online /cleanup-image /scanhealth
dism /online /cleanup-image /restorehealth

If you’re unable to get it resolved with the above steps feel free to

8 responses to “Fix Windows Update Error 800f0831”

  1. Thanks for this!!!!
    I tried all the usual repair steps, windows update repair tool, SSU update, etc etc. Nothing worked. Your advice was spot on. I found the problem service pack (KB4541509 in my case) in the CBS log file and everything is now working correctly.
    Thanks for saving my from pulling my remaining hair out. Cheers!

  2. Normally I do not learn article on blogs, however I would like to say that thiswrite-up very forced me to take a look at and do so!Your writing taste has been amazed me. Thankyou, very great post.

  3. My programmer is trying to convince me to move to .net from PHP.I have always disliked the idea because of the expenses.But he’s tryiong none the less. I’ve been using Movable-type on numerrous websites for about a year and aam nervous about switching toanother platform. I have heard fantastic things about there a way I can import all my wordpress content into it?Any heelp would be greatly appreciated!

  4. Thanks a lot! Microsoft provides 10 pages of information for same thing. You provided what we need – few steps and how to look it. Thanks again!

  5. Thank you! Thank you! Thank you! This worked for me after having this problem happen to a second server. The first time this happen was over the summer and I had to rebuild a new VM. That was a pain not because I had to rebuild windows server 2012 but because of the application that needed to run on it. Caused us a lot o down time. Happen again to a different server last night when trying to update it. Thought I may have had to rebit another server but ran into this site. Saved me a lot of pain and suffering. Thanks you again!

  6. It’s 2023 and you saved my ass brother, thank you! Just migrated from 2012 R2 Essentials and could not demote the old server or remove any roles until I could sort this mess down… Love you 🙂

Leave a Reply

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