0

I have the option to host multiple domains on a shared hosting account. I must host my primary domain in the root folder and other can be hosted within that root folder with separate folder for each domain hosted thereof. The primary domain domain1.com runs perfectly fine. But when I created a new folder for my domain2.com with folder name "domain2" to which it is configured for and uploaded a static welcome.html page it showed the following error:

Server Error in '/domain2' 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' or one of its dependencies. The system cannot find the file specified.

Source Error: 


Line 37:            <providers>
Line 38:                <clear/>
Line 39:                <add connectionStringName="domain1MembershipDB" applicationName="/" autogenerateschema="true" name="MySqlRoleProvider" type="MySql.Web.Security.MySQLRoleProvider, MySql.Web"/>
Line 40:            </providers>
Line 41:        </roleManager>

Source File: D:\Hosting\4343434\html\web.config    Line: 39 

Assembly Load Trace: The following information can be helpful to determine why the assembly 'MySql.Web' could not be loaded.


WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

Version Information: Microsoft .NET Framework Version:4.0.30319; ASP.NET Version:4.0.30319.272

But this is the line that corresponds to the web.config file of my primary domain domain1.com and the domain1.com still works fine.

Am I missing any little piece of information?

hungrycoder
  • 507
  • 2
  • 9
  • 24

1 Answers1

1

This is because your secondary domain inherits the web.config definitions but it doesn't have a reference to the necessary dll MySql.Web.dll.

You can clear the connection string of the upper level if you add in the secondary domain:

<roleManager>
   <providers>
     <clear/>
   </providers>
</roleManager>
Amiram Korach
  • 13,056
  • 3
  • 28
  • 30