Start a conversation

Error: "Could not load file or assembly" When Loading the GFI Archiver Web Interface

Overview

This article provides a solution to an error you may encounter when loading the GFI Archiver Web Interface.

Information

The following error is displayed when loading the web interface of GFI Archiver:

Server Error in '/Archiver' Application.
Configuration Error

Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Could not load file or assembly 'MySql.Web, Version=6.7.4.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d' or one of its dependencies. The system cannot find the file specified.

Source Error:

Line 245: <providers>
Line 246: <add name="AspNetSqlProfileProvider" connectionStringName="LocalSqlServer" applicationName="/" type="System.Web.Profile.SqlProfileProvider, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
Line 247: <add name="MySQLProfileProvider" type="MySql.Web.Profile.MySQLProfileProvider, MySql.Web, Version=6.7.4.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d" connectionStringName="LocalMySqlServer" applicationName="/" />
Line 248: </providers>
Line 249: </profile>

Source File:

C:\WINDOWS\Microsoft.NET\Framework64\v4.0.30319\Config\web.config Line: 247

The debug log ..\GFI\Archiver\ASPNET\UI\DebugLogs\UserProfileHelper.log reads:

2013-10-16,12:50:24,796,1,"#00001E14","#00000010","info   ","UserProfileHelper","Could not get LastMailArchiverIAccessed from profile, Details:System.Configuration.ConfigurationErrorsException: Could not load file or assembly 'MySql.Web, Version=6.7.4.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d' or one of its dependencies. The system cannot find the file specified. (C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Config\machine.config line 247) ---> System.IO.FileNotFoundException: Could not load file or assembly 'MySql.Web, Version=6.7.4.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d' or one of its dependencies. The system cannot find the file specified.
;   at System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMarkHandle stackMark, IntPtr pPrivHostBinder, Boolean loadTypeFromPartialName, ObjectHandleOnStack type)
;   at System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean loadTypeFromPartialName)
;   at System.Type.GetType(String typeName, Boolean throwOnError, Boolean ignoreCase)
;   at System.Web.Compilation.BuildManager.GetType(String typeName, Boolean throwOnError, Boolean ignoreCase)
;   at System.Web.Configuration.ConfigUtil.GetType(String typeName, String propertyName, ConfigurationElement configElement, XmlNode node, Boolean checkAptcaBit, Boolean ignoreCase)
;   --- End of inner exception stack trace ---
;   at System.Web.Profile.ProfileBase.InitializeStatic()
;   at System.Web.Profile.ProfileBase.Create(String username, Boolean isAuthenticated)
;   at System.Web.HttpContext.get_Profile()
;   at MArc.Web.UserProfileHelper.GetLastMailArchiverIAccessed()"

This error occurs because the Internet Information Services (IIS) is configured in a conflicting way.

Process

IMPORTANT: When upgrading to a newer version of GFI Archiver, the installation files mentioned in this procedure will be overwritten with the default versions, making the changes void and ineffective. Therefore, we suggest keeping a record of this procedure and follow it once again, directly after upgrading, to keep this functionality intact.

WARNING: This procedure requires to edit files manually. If edited incorrectly it can leave the server in a non-operational state. Please keep backups of any file which is edited throughout this article before saving any changes to them.

To fix this issue, follow the steps below:

  1. Open the folder ..\GFI\Archiver\ASPNET\UI.
  2. Open the file web.config in Notepad.
  3. Find the section which reads:
    <profile defaultProvider="MyProvider">
    <providers>
    <add name="MyProvider" type="MarProvider.MArcProfileProvider" profileStorePath=""/>
    </providers>
  4. Add the following line to the <providers> section:
    <remove name="MySQLProfileProvider" />
  5. The result should look like:
    <profile defaultProvider="MyProvider">
    <providers>
    <add name="MyProvider" type="MarProvider.MArcProfileProvider" profileStorePath=""/>
    <remove name="MySQLProfileProvider" />
    </providers>
  6. Save the file.

Confirmation

The GFI Archiver Web Interface loads successfully.

Choose files or drag and drop files
Was this article helpful?
Yes
No
  1. Priyanka Bhotika

  2. Posted

Comments