环境:Windows 2008 R2& ASP.Net 4.0
连接器/网络6.6.4从here
注意:我选择了“.Net / Mono”平台并下载了与架构无关的版本. Enable-32-bit-application-in-IIS对我来说不是一个选择.
我尝试通过以下连接字符串连接mySQL数据库.
Server=192.168.1.200;Port=3306;Database=gm_log;Uid=cf2;Pwd=123456;Charset=utf8;AllowUserVariables=True;Allow Zero Datetime=false;PersistSecurityInfo=false;Pooling=true;ConnectionLifeTime=0;Max Pool Size=100;Min Pool Size=1;
并且MySqlConnection.Open抛出一个OverflowException.算术运算导致溢出
这是堆栈跟踪.
at MySql.Data.MySqlClient.Authentication.MySqlAuthenticationPlugin.HandleAuthChange(MySqlPacket packet)
at MySql.Data.MySqlClient.Authentication.MySqlAuthenticationPlugin.Authenticate(Boolean reset)
at MySql.Data.MySqlClient.NativeDriver.Open()
at MySql.Data.MySqlClient.Driver.Open()
at MySql.Data.MySqlClient.Driver.Create(MySqlConnectionStringBuilder settings)
at MySql.Data.MySqlClient.MySqlPool.CreateNewPooledConnection()
at MySql.Data.MySqlClient.MySqlPool..ctor(MySqlConnectionStringBuilder settings)
at MySql.Data.MySqlClient.MySqlPoolManager.GetPool(MySqlConnectionStringBuilder settings)
at MySql.Data.MySqlClient.MySqlConnection.Open()
其他人遇到同样的问题?
解决方法:
从此处降级到之前的版本:
它现在适合我.
标签:mysql-connector,mysql,ado-net
来源: https://codeday.me/bug/20190725/1536633.html