Did you run the bcdedit |find "osdevice" command first to determine the correct partition ?
Edit - Been having another dig around for the "resource protection" error and found this which worked for someone, but academic now.
Perhaps Shane could comment, but once the repair install is complete, try the offboot sfc /scannow again.
------------------------------------------------------------------------------------------------------------------
Ok folks quit your freakout...the answer exists and Google can find it. I fixed it on mine.
My symptoms:
•Windows update fails
•Manual install of service pack fails
•sfc fails
•Windows Modules Installer (aka TrustedInstaller) won't run and returns error 126
•...other stuff I can't remember fails
•Errors like CO_E_SERVER_EXEC_FAILURE(0x80080005)
I read through a number of threads like this, here and on other sites. I tried the instructions above to no avail (although I can't be sure they weren't part of the solution). Then I found this:
http://www.vistax64.com/tutorials/282940-windows-modules-installer-error-126-fix.htmlThere is much detail there, written in broken English, with screenshots provided. Here is what worked for me, partially copypasta and partially paraphrased for brevity and clarity:
I was missing the following registry key:
HKLM\Software\Microsoft\Windows\CurrentVersion\Component Based Servicing\Version.
To fix it:
1. Navigate to C:\Windows\Servicing\Version and read the name of a subfolder. It will be named something like 6.1.7600.16385. That is your {TrustedInstaller ID}. Copy the name of that folder to the clipboard (and paste it in Notepad for safe keeping).
2. Find a subfolder in C:\Windows\WinSxS whose name starts with:
x86_microsoft-windows-servicingstack_31bf3856ad364e35_{TrustedInstaller ID} (32bit Windows)
amd64_microsoft-windows-servicingstack_31bf3856ad364e35_{TrustedInstaller ID} (64bit Windows)
Copy the name of that folder to the clipboard (and paste it in Notepad for safe keeping).
3. Create subkey "HKLM\Software\Microsoft\Windows\CurrentVersion\Component Based Servicing\Version". You will need to take ownership of "Component Based Servicing" then give yourself full access permissions before you can create the key.
4. In the new Version key, create an "expandable value" using the TrustedInstaller ID as its name and the complete path of the folder you identified in WinSxS as its value. Properly you should use %SystemRoot%\WinSxS\whatever instead of C:\Windows\WinSxS\whatever.