Monday, October 31, 2011

Archive Viewer Installation Error on IIS 7

A customer recently experienced an issue installing Instant Archive Viewer 4.0.82.  When clicking the button on the install launcher to install Archive Viewer, the installer will appear to hang for a few seconds, before reporting that the installer was interrupted.


To pinpoint the error, we had to enable logging in the MSI.  Since the installer msi requires administrator rights, we need to run cmd as an administrator.  The easiest way to do this is to enter cmd.exe into the start search box, and then press CTRL+SHIFT+ENTER.

This will bring you to the trusty command prompt.  You'll need to navigate to the directory to which you have downloaded the installer package for Instant Archive Viewer.  Once there, type:
cd "Instant Archive Viewer for OCS"
msiexec /i  InstantAV4.msi /lv log.txt
 The installer will once more fail to run, but this time it will generate a log of all the actions it undertook before failing.  Open log.txt in notepad or your text-editor of choice.  It will look something like this:

 The file should end in something similar to the following (There may be more or less detail).
Action start 13:14:57: WEBCA_SetTARGETSITE.
INFO   : [10/31/2011 13:14:57:873] [SetTARGETSITE                           ]: Custom Action is starting...
INFO   : [10/31/2011 13:14:57:874] [SetTARGETSITE                           ]: CoInitializeEx - COM initialization Apartment Threaded...
ERROR  : [10/31/2011 13:15:27:943] [SetTARGETSITE                           ]: FAILED: -2146959355
ERROR  : [10/31/2011 13:15:27:945] [SetTARGETSITE                           ]: Custom Action failed with code: '5'
INFO   : [10/31/2011 13:15:27:946] [SetTARGETSITE                           ]: Custom Action completed with return code: '5'
CustomAction WEBCA_SetTARGETSITE returned actual error code 1603 (note this may not be 100% accurate if translation happened inside sandbox)
Action ended 13:15:27: WEBCA_SetTARGETSITE. Return value 3.
Action 13:15:27: FatalErrorForm. 
Action start 13:15:27: FatalErrorForm.
 What Does This Mean?


This error message, cryptic though it may be, reveals that IIS compatibility services for IIS6 in IIS 7 are either not installed, or are not working correctly.  Instant Archive Viewer relies on these compatibility services to run.   Fortunately, it is simple enough to install these services.

Go to Control Panel -> Programs and Features and select Turn Windows features on and off.


On Server 2008, this will open Server Manager.  Expand Roles, then right-click on Web Server (IIS) and select Add Role Services.



Locate Management Tools, and check IIS 6 Management Compatibility.  Click install.  You may now proceed to installing Instant Archive Viewer.

Wait, That's Already Installed...

If these services are already installed, but you cannot install Archive viewer, then you'll need to check that all IIS services are running, particularly IIS Admin Service.

Open Control Panel -> Services, and locate IIS Admin Service.  Right-click and select Start.  If the service started correctly, you should now be able to install Archive Viewer.

Service Won't Start...


You're going to have to open Event Viewer.
Select Windows Logs -> System in the sidepane, and look for the last error caused by Service Control Manager.

If you see this error code, then it means that IIS has a corrupted metabase file.  It is unclear what could cause the metabase file to be corrupted, but, as it acts as a central store of configuration information in IIS 6, it is essential in order to run IIS Admin Service.  Fortunately, it is relatively easy to repair.

Open Windows Explorer.  Navigate to C:\Windows\System32\inetsrv


Locate MetaBase.xml and MBSchema.xml.  There may also be a file called MBSchema.bin.00000000h.

There should be a folder called History.  This folder contains backups of MetaBase.xml and MBSchema.  Select one of each, with matching revision numbers (For instance, MBSchema_0000000021_00000000.xml and MetaBase_0000000021_00000000.xml), and rename them to MetaBase.xml and MBSchema.xml.

Copy these two files to C:\Windows\System32\inetsrv, overwriting the existing files.  If the MBSchema.bin file exists, delete it.

Open cmd and enter the following to restart IIS:
iisreset
You should see:
C:\>iisreset
Attempting stop...
Internet services successfully stopped
Attempting start...
Internet services successfully restarted
C:\>
 You should now be able to install Instant Archive Viewer.

2 comments:

Manjunath B.E said...

Thanks a lot,,,very useful

Clint said...

Works like a charm. Thank you!