Windows 10: Canonical method to find and fix corrupt boot files on unbootable PC?

  1.    13 Aug 2016 #1

    Canonical method to find and fix corrupt boot files on unbootable PC?


    Hi all,

    I am having a repeat problem: my unstable PC BSODed while I wasn't doing anything, rebooted and then BSODed again on boot (0xc000021a), rebooted to the repair environment, which failed to fix it: my machine is unbootable. As before, booting to safe mode is impossible.

    I am fairly sure that physical damage to my hardware has rendered something seriously screwy and I will replace the thing soon. Until that time I would like to get my PC back up and running so I have something to use, take backups and so on.

    Now, the logfiles the diagnostics leave in Windows\System32\LogFiles\Srt\ are not very helpful. Yesterday it said that a critical boot file was corrupt but did not say which one(s). Today it says that "a patch is preventing the system from starting" but that the repair action, "System files integrity check and repair" failed with error code 0x57.

    My understanding is that the correct course of action would now be to run SFC on the offending system. So I booted to the recovery environment, clicked through to the command prompt, and tried it. However, SFC fails; running
    Code:
    sfc /scannow
    performs the verification stage and spits out:

    Code:
    Windows Resource Protection could not perform the requested operation.
    Now in spite of the frequent recommendation to run this command, my limited understanding is that this is useless anyway, as it is checking the files of the recovery environment. However, running
    Code:
    sfc /scannow /offbootdir=f: /offwindir=f:\windows
    (F:\ is my boot drive when in the recovery environment) gives the same error but doesn't leave a log file to work out what might have gone wrong. Replacing /scannow with /verifyonly doesn't help.

    This error message seems completely general and of no use in working out what's preventing SFC from doing its job. The same occurs if I boot from installation media and run the commands from the command prompt in its own repair environment. I want to avoid having to nuke all the installed stuff (again) because even though I can keep my data, setting everything up for the billionth time gets tiring, and I will just have to do it again when I replace this machine.

    So my question is: how can I replace these corrupted files? It seems like, certainly when running this stuff from installation media, it should not have any problems running SFC (I can imagine that the repair environment on the PC itself might also be boned). I have heard that DISM is a useful tool in this situation but I don't understand what it could be useful for since I'm not dealing with image files. Or am I taking it too literally, and does an installed version of windows count as an "unpacked" image? I don't know, it seemed to be exclusively for either altering a windows image file, or for altering an online (which I took to mean "booted") version of windows.

    When I do try to use DISM I think it should be something like this:

    Code:
    dism /image:f:\ /cleanup-image /restorehealth
    But this gives the following error (after completing the progress bar):

    Code:
    Error: 87
    
    An error occurred while processing the command.
    Ensure that the command-line arguments are valid. For more information, review the log file.
    The logfile contains a bunch of errors. The first errors are about XML parsing, but (of course) it does not say what XML file. They look like "CBS Wrong XML DECL [HRESULT = 0x800f0900 - CBS_E_XML_PARSER_FAILURE" (and some other iterations - I can type them up if it would help) and continue for quite a while. After those errors come some from CSI about mismatched hashes, which I fully expect to see. They are for files under f:\Windows\WinSxS. The summary says that 31 instances of CBS manifest corruption were found, and nothing else.

    Just before the corrupted packages are enumerated, the following errors appear:

    Code:
    CSI    00000014 (F) STATUS_INVALID_PARAMETER #174# from CCSDirect_IRtlComponentStore::EnumStoreCorruptions(...)[gle=0xd000000d]
    CSI    00000015 (F) E_INVALIDARG #173# from Windows::COM::CStorePendingStoreRepairTxn_IStorePendingStoreRepairTransaction::Detect(Flags = 5, cancelEvt = 3bc (""), disp = 0)[gle=0x80070057]
    CBS    Rept: Failed to call CSI detect. [HRESULT = 0x80070057 - E_INVALIDARG]
    The E_INVALIDARG error is then repeated in a few other places, but not with any new info that I can see.

    Thanks for any help you can offer.
    Last edited by FishFace; 13 Aug 2016 at 10:36.
      My ComputerSystem Spec

  2. Slartybart's Avatar
    Posts : 3,506
    Win_8.1-Pro, Win_10.1607-Pro, Mint_17.3
       13 Aug 2016 #2

    For the 0xc000021a error:

    You forgot the backslash in the offbootdir parameter, although it might not make a difference

    sfc /scannow /offbootdir=f: /offwindir=f:\windows
    should be:
    sfc /scannow /offbootdir=f:\ /offwindir=f:\windows

    If that doesn't help try removing any recent hardware (or any non-essential hardware - leave the mouse, keybd, and monitor)


    Today it says that "a patch is preventing the system from starting" but that the repair action, "System files integrity check and repair" failed with error code 0x57.

    Indicates that you can boot. Try uninstalling the most recent update in Windows Update, disconnect from the internet and restart.

    You should also run Windows Defender Offline

    Settings > Update and Security > Defender > Windows Defender Offline ... press the scan offline button
      My ComputerSystem Spec

  3.    13 Aug 2016 #3

    Slartybart said: View Post
    For the 0xc000021a error:

    You forgot the backslash in the offbootdir parameter, although it might not make a difference
    sfc /scannow /offbootdir=f: /offwindir=f:\windows
    should be:
    sfc /scannow /offbootdir=f:\ /offwindir=f:\windows

    I tried this but the result was the same.


    If that doesn't help try removing any recent hardware (or any non-essential hardware - leave the mouse, keybd, and monitor)
    No recent hardware additions. The history of the machine leaves me fairly confident that the hardware is damaged and doing this at random.

    Today it says that "a patch is preventing the system from starting" but that the repair action, "System files integrity check and repair" failed with error code 0x57.

    Indicates that you can boot.
    Nevertheless I cannot. Rebooting results in the same BSOD (or a trip to the recovery environment - it alternates, of course)
      My ComputerSystem Spec

  4. Slartybart's Avatar
    Posts : 3,506
    Win_8.1-Pro, Win_10.1607-Pro, Mint_17.3
       13 Aug 2016 #4

    That's all I have - the errors do indicate hardware, but that could also be faulty drivers

    Can you boot to Safe Mode?

      My ComputerSystem Spec

  5.    13 Aug 2016 #5

    Nope, safe mode BSODs with the same message.
      My ComputerSystem Spec

  6. Slartybart's Avatar
    Posts : 3,506
    Win_8.1-Pro, Win_10.1607-Pro, Mint_17.3
       13 Aug 2016 #6

    Thought of some other things - might work ...

    Remove your memory - place one stick in the first slot and try a restart
    place the same stick in each of the other slots - trying a restart between each change

    Then if there is more than one RAM stick involved, try the same procedure with the other RAM stick(s)

    This tests each RAM stick independently of any other RAM and it test the slots as well


    Tools that are good to have in your toolbox (to effectively use the Fix boot features you should know the disk structure - that's where Partition Wizard comes into play)

    Read up on the utilities and ask questions before you attempt a repair.

      My ComputerSystem Spec


 

Related Threads
When I run sfc /scannow, these are the problems that can't be fixed: 2016-04-17 17:10:09, Info CSI 000051ab Cannot repair member file "Snipping Tool.lnk" of Microsoft-Windows-SnippingTool-App, version 10.0.10586.0, arch...
Is there currently any way to configure a custom boot logo for UEFI booting? I can only find methods for Legacy users, but no luck with UEFI. I'm kind of new to custom boot logos, so if anybody could give me some information as to if it's...
Solved Image Files Created via thw Windows 7 method in Performance & Maintenance
I have been working on a new Dell laptop with Windows 10 Home while thinking about if I will ever update my Windows 7 64 bit Ultimate machine, which I am thinking not doing. Only wanted laptop for backup as this Optiplex has run 24X7 for 9 years 4...
Solved SFC Corrupt Files on CBS.Log in Performance & Maintenance
Trying to run down some error codes in the admin log I decided to run the SFC scan to see if any files were corrupt and many were which were fixed except for 2 and was wondering if anyone here knows how to read and make fixes to the CBS.log, thanks
Solved SFC Corrupt Files in Performance & Maintenance
Windows search doesn't work. I ran SFC /scannow and there is corrupt files, the log is attached.
Our Sites
Site Links
About Us
Windows 10 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 10" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd
All times are GMT -5. The time now is 03:13.
Find Us
Twitter Facebook Google+ Ten Forums iOS App Ten Forums Android App



Windows 10 Forums