1

Setup:

Windows 7 SP1 64 bit Visual Studio 2012 MySQL .Net Connector 6.6.4

I have a vb .net WinForm app which connects to a MySQL server using the MySQL .Net Connector. It was working perfectly. I then formatted the pc, reinstalled the same version of windows as before, but I installed a slightly newer version of the MySQL .Net Connector, as well as Visual Studio 2012 instead of 2010.

When the code where I open the connection executes, i.e.:

Dim mySQLcon As New MySql.Data.MySqlClient.MySqlConnection("SERVER=www.tadirect.co.za;DATABASE=tadirq_db1;UID=********;PASSWORD=********;")
mySQLcon.Open()

At the mySQLcon.Open() line I get the following exception:

System.OverflowException: Arithmetic operation resulted in an overflow at MySql.Data.MySqlClient.Authentication.MySqlAuthenticationPlugin.HandleAuthChange(MySqlPacket packet)
at MySql.Data.MySqlClient.Authentication.MySqlAuthenticationPlugin.Authenticate(Boolean reset)
at MySql.Data.MySqlClient.NativeDriver.Authenticate(String authMethod, 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.GetPooledConnection()
at MySql.Data.MySqlClient.MySqlPool.TryToGetDriver() at MySql.Data.MySqlClient.MySqlPool.GetConnection()
at MySql.Data.MySqlClient.MySqlConnection.Open()
at TAD_Automator.modWebsite.UpdateMySQLDatabase_Cases(Boolean bSilent)}

I have tried changing the build from Any CPU to 32 bit as well as 64 bit but it made no difference...

Any ideas? It used to work before I reinstalled Windows/VS/MySQL...

1
  • try to write your question simple and precise..too lengthy will annoy the people Commented Dec 13, 2012 at 12:18

2 Answers 2

1

I found a solution. Install MySQL connector 6.1.6 and you will solve the problem.

Sign up to request clarification or add additional context in comments.

Comments

0

I believe MySQL dropped support for the old style of password encryption that they were using prior to 6.6. I had the same problem and I had to turn off the old_password support on my DB Server and then recreate the user so that the new password function is used to hash the password.

Check out this bug thread: http://bugs.mysql.com/bug.php?id=67953

Check out this link for more information: http://dev.mysql.com/doc/refman/5.0/en/old-client.html

Being a novice at this, it was easier for me to delete the user in question, change the DB options to turn off old_password encryption and authentication using MySQL Workbench, restart the DB Server, then recreate the user. This solved the problem for me. Hope this helps you - good luck.

1 Comment

You don't need to delete the user. Just reset the password from a client that can still login with the old one (after turning off the option, of course).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.