[SOLVED] Windows 7 SP1 - Error 0800040005 updating PowerShell 2 to 5.1

epardieu

Member
Joined
May 19, 2019
Posts
7
Hi there!
I need to update my PowerShell to a 5.1 version available for my Win 7 sp1. I've got these lines in the windowsupdate.log:

2019-05-19 17:43:51:026 13720 1c08 Handler :::::::::::::
2019-05-19 17:43:51:027 13720 1c08 Handler :: START :: Handler: CBS Install
2019-05-19 17:43:51:027 13720 1c08 Handler :::::::::
2019-05-19 17:43:51:028 13720 1c08 Handler Starting install of CBS update C05F0AEA-8F8F-4EA3-A247-433C3B681C72
2019-05-19 17:43:51:064 13720 1c08 Handler CBS package identity: Microsoft-Windows-WinMan-WinIP-Package-TopLevel~31bf3856ad364e35~amd64~~7.3.7601.16384
2019-05-19 17:43:51:065 13720 1c08 Handler Installing self-contained with source=C:\Windows\SoftwareDistribution\Download\8460062166f4d27e0b98e704f8682603\Windows6.1-KB3191566-x64.cab, workingdir=C:\Windows\SoftwareDistribution\Download\8460062166f4d27e0b98e704f8682603\inst
2019-05-19 17:43:56:000 1416 12a4 Report REPORT EVENT: {B7758F33-1723-4357-8999-BB8C0A00B59F} 2019-05-19 17:43:51:000-0300 1 181 101 {FFBF75AD-7C02-433B-9D69-649EFB9E93A9} 501 0 wusa Success Content Install Installation Started: Windows successfully started the following update: Actualización para Windows (KB3191566)
2019-05-19 17:56:36:891 13720 3734 Handler FATAL: CBS called Error with 0x80004005,
2019-05-19 17:56:43:000 13720 1c08 Handler FATAL: Completed install of CBS update with type=0, requiresReboot=0, installerError=1, hr=0x80004005
2019-05-19 17:56:43:681 13720 1c08 Handler :::::::::
2019-05-19 17:56:43:681 13720 1c08 Handler :: END :: Handler: CBS Install
2019-05-19 17:56:43:681 13720 1c08 Handler :::::::::::::
2019-05-19 17:56:43:683 1416 2bbc Agent LogHistory called. idUpdate={FFBF75AD-7C02-433B-9D69-649EFB9E93A9}.501, resultMapped=80004005, resultUnMapped=80004005
2019-05-19 17:56:43:690 1416 2bbc Agent *********
2019-05-19 17:56:43:690 1416 25a8 AU Triggering Offline detection (non-interactive)
2019-05-19 17:56:43:690 1416 2bbc Agent ** END ** Agent: Installing updates [CallerId = wusa]
2019-05-19 17:56:43:690 3552 1054 COMAPI >>-- RESUMED -- COMAPI: Install [ClientId = wusa]
2019-05-19 17:56:43:690 1416 25a8 AU #############
2019-05-19 17:56:43:690 1416 2bbc Agent *************
2019-05-19 17:56:43:690 3552 1054 COMAPI - Install call complete (succeeded = 0, succeeded with errors = 0, failed = 1, unaccounted = 0)
2019-05-19 17:56:43:690 1416 25a8 AU ## START ## AU: Search for updates
2019-05-19 17:56:43:690 1416 25a8 AU #########
2019-05-19 17:56:43:690 3552 1054 COMAPI - Reboot required = No
2019-05-19 17:56:43:690 3552 1054 COMAPI - WARNING: Exit code = 0x00000000; Call error code = 0x80240022
2019-05-19 17:56:43:690 3552 1054 COMAPI ---------
2019-05-19 17:56:43:690 3552 1054 COMAPI -- END -- COMAPI: Install [ClientId = wusa]
2019-05-19 17:56:43:690 3552 1054 COMAPI -------------

Bold part lead me to research about windows update problem and finally got here.
I ran all steps in this forum, SFC scan with no issues and I've got SFCFix.txt and CBS.log, I'm sharing with you at:
Windows Update - Google Drive
In order to help to solve this issue, it'll let me keep going with another issue regarding Vagrant VM for a MongoDB course.
Thank you in advance.

Regards,
Eliana
 
Hi welcome to Sysnative,


It seems one update isn't properly installed lets remove it, by executing the following steps:


Remove Update using Dism
  1. Please download KB4489878 http://download.windowsupdate.com/c..._ad02ba6500855333621fecf1b95cc15a8950f2e8.msu save the file to c:\windows\temp
  2. change the name of the update file to a smaller name windows6.1-KB4489878-x64.msu
    (keep the extension .msu in the end of the file name in case its visible if not ignore that)
  3. open the Command Prompt as Administrator (Tutorial)
  4. type or Copy & Paste the following commands line by line:

    cd /d c:\windows\temp
    expand windows6.1-KB4489878-x64.msu -f:* C:\windows\temp
    DISM.exe /Online /Remove-Package /PackagePath:C:\windows\temp\windows6.1-KB4489878-x64.cab

  5. You should receive the message:
    The operation completed successfully.
    Restart Windows to complete this operation.
    Do you want to restart the computer now (Y/N)?
  6. Make sure to allow the computer to restart if prompted.

    If you receive any other message:
  7. Right-click on the Command Prompt window and click Select All, this will invert all of the colours by selecting the text, now press enter. All of this text is now copied.
  8. Paste (Ctrl+V) it into your next post please.
 
Hi SleepyDude,
I've followed all the steps and as a result I have this:
Microsoft Windows [Versión 6.1.7601]
Copyright (c) 2009 Microsoft Corporation. Reservados todos los derechos.

C:\Windows\system32>cd temp
El sistema no puede encontrar la ruta especificada.

C:\Windows\system32>cd..

C:\Windows>cd temp

C:\Windows\Temp>expand windows6.1-KB4489878-x64.msu -f:* C:\windows\temp
Microsoft (R) Utilidad de expansión de archivos versión 6.1.7600.16385
Copyright (c) Microsoft Corporation. Reservados todos los derechos.

No se puede abrir el archivo de entrada: windows6.1-kb4489878-x64.msu.


C:\Windows\Temp>expand windows6.1-KB4489878-x64.msu -f:* C:\windows\temp
Microsoft (R) Utilidad de expansión de archivos versión 6.1.7600.16385
Copyright (c) Microsoft Corporation. Reservados todos los derechos.

Agregar C:\windows\temp\WSUSSCAN.cab a la cola de extracción
Agregar C:\windows\temp\Windows6.1-KB4489878-x64.cab a la cola de extracción
Agregar C:\windows\temp\PkgInstallOrder.txt a la cola de extracción
Agregar C:\windows\temp\PCIClearStaleCache.exe a la cola de extracción
Agregar C:\windows\temp\Windows6.1-KB4489878-x64-pkgProperties.txt a la cola de extracción
Agregar C:\windows\temp\Windows6.1-KB4489878-x64.xml a la cola de extracción

Expandiendo archivos ....

Se completó la expansión de archivos ...
6 total de archivos.

C:\Windows\Temp>DISM.exe /Online /Remove-Package /PackagePath:C:\windows\temp\windows6.1-KB4489878-x64.cab

Herramienta Administración y mantenimiento de imágenes de implementación
Versión: 6.1.7600.16385

Versión de imagen: 6.1.7601.18489

Procesando 1 de 1: Quitando paquete Package_for_RollupFix~31bf3856ad364e35~amd64~~7601.24385.1.9
[===========================99.7%========================= ]
Error: Package_for_RollupFix Error: 0x80004005

Error: 0x80004005

Error de DISM. No se realizó ninguna operación.
Para obtener más información, revise el archivo de registro.

El archivo de registro de DISM se encuentra en C:\Windows\Logs\DISM\dism.log

C:\Windows\Temp>

And I've attached here the metioned dism log.
I hope this can shape up a solution. Is this error expected?
Thanks for taking care of my issue!!
 

Attachments

Hi,

The dism log isn't very informative, please do the following:

Locate the log c:\Windows\logs\cbs\CBS.log copy the file to the Desktop, Zip it and attach to your post.

Note: If the file is too big to attach please upload it to a service like Dropbox, Google Drive, OneDrive or upload to SendSpace and just provide the link for the file here.
 
My mistake! I'm so sorry. Here is cbs.rar

Not at all.

We have to remove the update manually but first I need more information...


Search with Farbar Recovery Scan Tool (FRST)
  • Download FRST or FRST x64 and save it to the Desktop.
    (Please pick the version that matches your operating system's bit type. If you don't know which version matches your system, try FRST if it say that is not compatible with your OS you have to use FRST64)
  • open the Command Prompt as Administrator (Tutorial)
  • Copy & Paste the command:
    dism /online /Get-FeatureInfo /FeatureName:TFTP|find "."
  • wait for the command to finish with "The operation completed successfully" or equivalent
  • close the window "Administrator: Command Prompt"
  • Execute FRST/FRST64 right click on the icon
    FRST.jpg
    and choose Run as Administrator. Make sure all other windows are closed.
    (When the Tool opens for the first time you must click Yes on the disclaimer.)
    FRST_SearchRegistry.png
  • On the Search box (1) type or Copy & Paste the following text:
    KB4489878
  • Press the Search Registry button.
  • Wait for the search to finish FRST will produce a log called (SearchReg.txt) in the same directory the Tool is run from.
  • Please attach the log to your post.
 
Hi,

Lets remove the update using FRST...


Farbar Recovery Scan Fix

!!! WARNING !!! The following fix is only relevant for this system and no other, running the script on another computer will not work and may cause problems...

  • Download the file attached and save it to the Desktop as fixlist.txt
    (It's important that both files, FRST or FRST64 and fixlist.txt are in the same location or the fix will not work!)
  • Execute FRST/FRST64 right click on the icon
    FRST.gif
    and choose Run as Administrator. Make sure all other windows are closed.
    FRST_Fix.png
  • Press the Fix button just once and Wait. After the fix the system needs to restart if the tool does not request it please Restart the computer.
  • The tool will make a log (Fixlog.txt) on the same location as FRST/FRST64 please post it in your next reply.
 

Attachments

Attached is the fixlog. Just a couple of questions... Is this procedure safe? Should I reinstall the sp1 for Win7?
 

Attachments

Attached is the fixlog. Just a couple of questions... Is this procedure safe? Should I reinstall the sp1 for Win7?

Thanks. Yes its something we have tested and done in several cases. No you don't need to reinstall SP1, AFAIK it doesn't install when its already installed.

Let windows search for updates, try to install them and if it fails report the error and collect the new CBS.log
 
Thank you very much for all your help and support. Finally, everything went fine and I'll continue with my MongoDB course.
 

Has Sysnative Forums helped you? Please consider donating to help us support the site!

Back
Top