Sunday, June 03, 2012

Microsoft Security Essentials trouble

Update: Over 2 years later (August 2014), I still come across this problem. This time, the error code was 0x8004ff19, but the solution was the same: delete "%PROGRAMFILES%\Microsoft Security Client" and re-install with the current installer.

It seems that there is a pretty bad problem with Microsoft Security Essentials. I was surprised to notice that it wasn't running on several machines. It turns out that an automatic upgrade through Windows Update fails in a very bad way: it sort of uninstalls the old version, and then fails to install the new version. Users don't notice anything special.

Trying to re-install it by hand also fails with a very informative message (as usual for MS error messages):

Cannot complete the Security Essentials installation
An error has prevented the Security Essentials setup wizard from completing successfully. Please restart your computer and try again.
Error code:0x80070005

Of course, clicking on the "Get help" link is of no help at all.

Apparently, the code "0x80070005" means "Access denied", but there is no way to find out to what the access was denied.

Searching through the event logs reveals other errors, which I will list here in the hope that it helps other Googlers

Log Name:      System
Source:        Microsoft-Windows-WindowsUpdateClient
Event ID:      20
Task Category: Windows Update Agent
Description: Installation Failure: Windows failed to install the following update with error 0x80070643: Microsoft Security Essentials Client Update Package - KB2691905.
Log Name:      Application
Source:        Microsoft Security Client Setup
Event ID:      100
Description: HRESULT:0x80070005
Description:Cannot complete the Security Essentials installation. An error has prevented the Security Essentials setup wizard from completing successfully. Please restart your computer and try again. Error code:0x80070005. Access is denied.

And also older errors which may or may not be related:

Log Name:      Application
Source:        SideBySide
Event ID:      72
Description: Activation context generation failed for "c:\program files\microsoft security client\MSESysprep.dll".Error in manifest or policy file "c:\program files\microsoft security client\MSESysprep.dll" on line 10. The element imaging appears as a child of element urn:schemas-microsoft-com:asm.v1^assembly which is not supported by this version of Windows.

Advice found on the web which didn't work:

  • Uninstall MSSE then re-install (it was not listed in the installed programs, so I couldn't uninstall it)
  • Uninstall any other anti virus software (I didn't have any)
  • Run OneCareCleanup (silly because it was never installed)
  • etc.

Anyway, after a lot of useless searching and trying, what worked for me was to simply
rmdir /S /Q "%PROGRAMFILES%\Microsoft Security Client"

(Be careful with rmdir /s /q ! It deletes the whole folder and sub-folders without asking first!)

After that, I could re-install normally.

But it is very disturbing to see that an antivirus can just stop working without any obvious alert or user notification.

PS: It turns out that even Mark Russinovich had a problem with MSSE. His immediate error was different, but was one I also eventually found in the logs. His solution was to delete the HKCR\Installer\UpgradeCodes\11BB99F8B7FD53D4398442FBBAEF050F registry key. I had tried his procmon tool to try to find what returned "access denied", but then decided to resort to some primitive and brutal approaches first...

Labels: , ,

9 Comments:

Anonymous GOSH said...

Thanks! Finaly! It realy works! I'm in IT more then 10 years, and must admit, that most solutions from Microsoft is absolutely useless. Hate them!

07 June, 2012 13:53  
Anonymous Anonymous said...

Thank you so much :)

20 June, 2012 11:53  
Anonymous Anonymous said...

After wasting hours trying Microsoft's 0x80070005 solutions I try your fix. WOW,MSE working again. Thank you. You are a Legend. Geoff C.

14 August, 2012 22:45  
Blogger Newbie89 said...

Hi,
I have tried uninstalling the MSE software with Microsoft Fixit tool after i could'nt delete it from control panel add/remove programs option. But after rebooting my system what happened was MSE kept showing error that it couldn't initialize...I kept wondering why this was happening because the installed program list did'nt show MSE anymore also my start panel still had a shortcut for MSE strangely after uninstalling. Now what I did was I manually deleted the C://Program Files/Microsoft Security Client installation folder. The only help I could get was there was no more error message from MSE saying " couldn't Initialize " after rebooting the system. but to my misery I can not still re-install MSE. Any help plzz

04 October, 2012 07:41  
Anonymous Anonymous said...

It works. Many thanks.

08 December, 2012 04:13  
Blogger Unknown said...

It works by deleting C: -> Program Files -> Microsoft Security Client

Looks like when installing Security Essential, a folder "Microsoft Security Client" will be created in Program Files under C drive .

If the folder is already there, the installation will be aborted with this error message.

08 December, 2012 15:59  
Anonymous Steve T said...

Wow! Why isn't this the top result on Google for this error? Lots of useless information to dig through first. Why the presence of the folder causes the installer to crash and burn makes no sense to me. This is almost certainly a bug in the installer and should be fixed.

Thanks for this.

12 June, 2013 19:36  
Anonymous Anonymous said...

Thanks a bunch. Your solution fixed my problem after hours of searching Microsoft and running the typical useless FIX-IT utilities to no avail.

16 July, 2013 04:17  
Anonymous Anonymous said...

my problem not yet solved :( unable to install the mse nad the command promt code that u have given is not working :(

12 May, 2014 18:43  

Post a Comment

<< Home