| Bug #56141 | Unknown Command message on connecting | ||
|---|---|---|---|
| Submitted: | 20 Aug 2010 11:37 | Modified: | 20 Aug 2010 19:38 |
| Reporter: | Bogdan Degtyariov | Email Updates: | |
| Status: | Closed | Impact on me: | |
| Category: | Connector / NET | Severity: | S3 (Non-critical) |
| Version: | 6.2.3 | OS: | Any |
| Assigned to: | CPU Architecture: | Any | |
| Tags: | connect | ||
[20 Aug 2010 19:38]
Reggie Burnett
Thank you for your bug report. This issue has been committed to our source repository of that product and will be incorporated into the next release.
If necessary, you can access the source repository and build the latest available version, including the bug fix. More information about accessing the source trees is available at
http://dev.mysql.com/doc/en/installing-source.html

Description: Pooled connections work well with MySQL 5.0.x and fail with MySQL 5.1.x with the exception: Unknown command at MySql.Data.MySqlClient.MySqlStream.ReadPacket() at MySql.Data.MySqlClient.NativeDriver.AuthenticateNew() at MySql.Data.MySqlClient.NativeDriver.Authenticate() at MySql.Data.MySqlClient.NativeDriver.Reset() at MySql.Data.MySqlClient.Driver.Reset() at MySql.Data.MySqlClient.MySqlPool.GetPooledConnection() at MySql.Data.MySqlClient.MySqlPool.TryToGetDriver() at MySql.Data.MySqlClient.MySqlPool.GetConnection() at MySql.Data.MySqlClient.MySqlConnection.Open() at _issues.Form1.bIssue50127_Click(Object sender, EventArgs e) in C:\Projects\NET-Projects\_issues\Form1.cs:line 197 This happens when application connects second time (1st connection attempt goes ok). See the test code for details (the connection string must be exactly as shown in the test case): NOTE: it does not fail if remove "using: statement How to repeat: const int numberOfConnections = 20; MySqlConnection[] connArray = new MySqlConnection[numberOfConnections]; for (int i = 0; i < numberOfConnections; ++i) { using (connArray[i] = new MySqlConnection()) { connArray[i].ConnectionString = "server=localhost;User Id=******;password=*****;port=3306;Persist Security Info=False;Use Procedure Bodies=True;pooling=True;Minimum Pool Size=0;Maximum Pool Size=200;Connection Lifetime=30;Connection Reset=True;Ignore Prepare=True;Allow Batch=True;logging=False"; connArray[i].Open(); } Thread.Sleep(50); }