Saturday, March 2, 2013

Windows Azure: SQL Server Issues with VC++ Manifests

Not only did I run into this issue once, but I ran into again after fixing it the first time. Same issue, same resolution steps, but slightly different causes. I believe the root cause is the Windows Updates to the VC++ redistributable files causing manifest files to be blank.

Initial Problem
I installed SQL Server on Windows Azure for a SharePoint Development environment. Everything was fine. I ran Windows Updates and rebooted. I think once the server was back up, I focused on installing SharePoint on a different virtual machine. Anyway, when I did finally come back to the SQL Server VM, I could not launch SQL Management Studio. I received an error:

The application has failed to start because its side-by-side configuration is incorrect.
 
 
Originally I thought I did something wrong as I was running installations and doing too many things at once. So the first time I just rebuild the server. After I did that and ran the Windows Updates and received the same error (The application has failed to start because its side-by-side configuration is incorrect.), I figured it wasn't me and maybe something else.
 
I found the solution to my intial problem here. The resolution worked like a charm. Essentially, the manifest file for the ATL80.DLL was blank. The steps from that forum post are here:
 
takeown /f C:\Windows\WinSxS\manifests\amd64_microsoft.vc80.atl_1fc8b3b9a1e18e3b_8.0.50727.4053_none_8a1a02152edb659b.manifest
icacls C:\Windows\WinSxS\manifests\amd64_microsoft.vc80.atl_1fc8b3b9a1e18e3b_8.0.50727.4053_none_8a1a02152edb659b.manifest /grant Administrators:F
notepad C:\Windows\WinSxS\manifests\amd64_microsoft.vc80.atl_1fc8b3b9a1e18e3b_8.0.50727.4053_none_8a1a02152edb659b.manifest


When the empty file (actually I saw some blank space in there) opens in notepad, you just need to paste the following in there are save:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?><!-- Copyright © 1981-2001 Microsoft Corporation --><assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">    <noInheritable/>    <assemblyIdentity type="win32" name="Microsoft.VC80.ATL" version="8.0.50727.4053" processorArchitecture="amd64" publicKeyToken="1fc8b3b9a1e18e3b"/>    <file name="ATL80.dll" hash="99840dcc34e78af239d80841eba316c184e407cd" hashalg="SHA1"/></assembly>

Worked great! I thought I was done!

Continued Problems
Today when I fired up my SharePoint site, it could not connect to the configuration database. When I remoted into my SQL Server VM and attempted to run SQL Server Management Studio, I received the same error: The application has failed to start because its side-by-side configuration is incorrect.

OK. I thought I knew how to fix it. But when I ran the commands above from the original forum post, the manifest file still had the contents in there. So it must be something else. Ahhh.

So I remembered I found a way to determine the errors from this post here.

You run the trace, perform the action that doesn't work, and then stop the trace and convert it to readable format. At the bottom of the log, you'll see the error similiar to this:

INFO: Parsing Manifest File C:\Windows\WinSxS\manifests\amd64_microsoft.vc80.atl_1fc8b3b9a1e18e3b_8.0.50727.6195_none_8a1dd9552ed7f8d8.manifest.
 INFO: Manifest Definition Identity is (null).
 ERROR: Line 0: XML Syntax error.
ERROR: Activation Context generation failed.

At one point before I did the trace, I just decided that I only needed SQL Server running and noticed the service was not active. When attempting to even start the service, I received a similiar error:

 
Windows could not start SQL Server (MSSQLSERVER) service on Local Computer.
Error 14001: The application has failed to start because its side-by-side configuration is incorrect.
 
 
I used the trace method and actually had to fix two additional manifest files - the x86 and the amd64 flavors of the 8.0.50727.6195 version of ATL80.dll. So to save people trouble, I included the commands and the content to paste back into the files.
 
 
x86 8.0.50727.6195

takeown /f C:\Windows\WinSxS\manifests\x86_microsoft.vc80.atl_1fc8b3b9a1e18e3b_8.0.50727.6195_none_d1cb102c435421de.manifest
icacls C:\Windows\WinSxS\manifests\x86_microsoft.vc80.atl_1fc8b3b9a1e18e3b_8.0.50727.6195_none_d1cb102c435421de.manifest /grant Administrators:F
notepad C:\Windows\WinSxS\manifests\x86_microsoft.vc80.atl_1fc8b3b9a1e18e3b_8.0.50727.6195_none_d1cb102c435421de.manifest


<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!-- Copyright © 1981-2001 Microsoft Corporation -->
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
    <noInheritable/>
    <assemblyIdentity type="win32" name="Microsoft.VC80.ATL" version="8.0.50727.6195" processorArchitecture="x86" publicKeyToken="1fc8b3b9a1e18e3b"/>
    <file name="ATL80.dll" hash="b5037a793da006b9cbf7497aad5886358a578095" hashalg="SHA1"/>
</assembly>
amd64 8.0.50727.6195
takeown /f C:\Windows\WinSxS\manifests\amd64_microsoft.vc80.atl_1fc8b3b9a1e18e3b_8.0.50727.6195_none_8a1dd9552ed7f8d8.manifest
icacls C:\Windows\WinSxS\manifests\amd64_microsoft.vc80.atl_1fc8b3b9a1e18e3b_8.0.50727.6195_none_8a1dd9552ed7f8d8.manifest /grant Administrators:F
notepad C:\Windows\WinSxS\manifests\amd64_microsoft.vc80.atl_1fc8b3b9a1e18e3b_8.0.50727.6195_none_8a1dd9552ed7f8d8.manifest

<?xml version="1.0" encoding="UTF-8" standalone="yes"?><!-- Copyright © 1981-2001 Microsoft Corporation --><assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">    <noInheritable/>    <assemblyIdentity type="win32" name="Microsoft.VC80.ATL" version="8.0.50727.6195" processorArchitecture="amd64" publicKeyToken="1fc8b3b9a1e18e3b"/>    <file name="ATL80.dll" hash="c7e340d6abcbb023cbfd848a292f6583f4227105" hashalg="SHA1"/></assembly>

Hope this helps!!!
 

No comments:

Post a Comment

Matched Content