无法初始化提供程序.缺少或不正确的架构

Aay*_*shi 3 mysql

我已经升级了我的服务器机器以使用MySQL Connector 6.3.4,并且在我们的网站中我们还添加了会员角色提供程序.

当我运行网站时,我收到此错误.

配置错误说明:处理为此请求提供服务所需的配置文件时发生错误.请查看下面的具体错误详细信息并相应地修改配置文件.

分析器错误消息:无法初始化提供程序.缺少或不正确的架构.

我的sql server是5.0.90版本的community-net.

升级连接器时是否有任何必须在服务器端进行更改的设置

这是我的web.config文件中的标记.

因为当我在本地机器上运行网站时它会成功运行,但在服务器上我无法运行它并且超出错误.连接字符串没有错误

升级连接器时我们要做的服务器端设置是什么....

谢谢

Gau*_*hta 6

我自己遇到了同样的问题.我使用Mysql连接器6.3.0.0到目前为止,我在网上搜索时遇到了以下建议:

1) Add "MySql.Data.dll" & "MySql.Web.dll" into your application  "bin" folder.
2) Add reference to above to dlls in your application .
3) Add autogenerateschema="true" in your web.config file for required sections.
4) Check your Mysql connector version - make sure that the one that is in your bin folder is mentioned in your web.config file. 
5) Check your connection string - make sure it is correct and connected successfully.
6) Check mysql membership related table structure.
7) Check schema version in "my_aspnet_schemaversion" table (e.g since you have upgraded to newer version I insist you should check this).
8) If the problem is on remote machine (e.g Production Server) you may wan to check this : http://www.reggieburnett.com/referencing-connectornet-on-a-remote-machine 
Run Code Online (Sandbox Code Playgroud)

我相信您可能会浏览此列表,但我希望您检查"my_aspnet_schemaversion"表中的架构版本(例如,比较本地和远程表的"版本"字段值),因为您升级到较新版本.

顺便说一句:我已经检查了这个列表以解决我的问题,但它没有帮助.我希望它对你有所帮助.

编辑:嗨,我们可以通过以下方式修复此错误:

1) Deleted the tables for memberships in the db and had the mysql membership provider regenerate them
2) than set the Aministration.config file to trust the Mysql Membership Provider (e.g related to IIS admin)
Run Code Online (Sandbox Code Playgroud)

问候,

拉夫

  • 嘿Gaurav!你是如何进行"编辑"部分的第二步的.我找到了Administration.config文件,但不知道如何让它信任Mysql成员资格提供程序 (2认同)