WebsitePanel and MySQL 5.5 Configuration Error

If you try and configure the MySQL 5 service in WebsitePanel 1.2.1 you may get the following error message:

System.Web.Services.Protocols.SoapException: System.Web.Services.Protocols.SoapException: System.Web.Services.Protocols.SoapException: Server was unable to process request. ---> System.IO.FileNotFoundException: Could not load file or assembly 'MySql.Data, Version=6.3.7.0, Culture=neutral, PublicKeyToken=c5687fc88969c44d' or one of its dependencies. The system cannot find the file specified.

This error is down to WebsitePanel looking for a specific version (6.3.7.0) of the MySQL .Net Connector.  In all likelihood, you will have installed either a later version (at the time of writing it is 6.5.4).

Thankfully, this is error is easy to fix and only requires modifying a couple of configuration files.  Add the following code snippet at the end of the web.config files before the closing </configuration> tag for both WebsitePanel’s server and portal components (the default paths are c:\websitepanel\server and c:\websitepanel\portal respectively):

1
&lt;runtime&gt;
1
&lt;assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"&gt;
1
&lt;dependentAssembly&gt;
1
&lt;assemblyIdentity name="MySql.Data" publicKeyToken="c5687fc88969c44d" /&gt;
1
&lt;bindingRedirect oldVersion="0.0.0.0-6.3.7.0" newVersion="6.5.4.0" /&gt;
1
&lt;/dependentAssembly&gt;
1
&lt;/assemblyBinding&gt;
1
&lt;/runtime&gt;

If you are using a version of the .Net Connector later than 6.5.4.0, then do amend the bindingRedirect newVersion property.

Leave a Reply

Your email address will not be published. Required fields are marked *