My SQL Error when i put in production: An established connection was aborted by the software in your host machine

-1

My website work normally in localhost but when i upload in production on A2Hosting(With MySQL 5.6) i receive this error.

An established connection was aborted by the software in your host machine

My connection string is:

<add name="Stockphotos_main_db" connectionString="server=70.32.28.70;Port=3306;User Id=<id>;database=<db_name>; password=<password>;Convert Zero Datetime=True" />

I dont know what i do, i try everyting... Look the stack trace:

[SocketException (0x2745): An established connection was aborted by the software in your host machine]
System.Net.Sockets.Socket.Receive(Byte[] buffer, Int32 offset, Int32 size, SocketFlags socketFlags) +106
System.Net.Sockets.NetworkStream.Read(Byte[] buffer, Int32 offset, Int32 size) +130

[IOException: Unable to read data from the transport connection: An established connection was aborted by the software in your host machine.]
MySql.Data.Common.MyNetworkStream.HandleOrRethrowException(Exception e) +91
MySql.Data.Common.MyNetworkStream.Read(Byte[] buffer, Int32 offset, Int32 count) +62
MySql.Data.MySqlClient.TimedStream.Read(Byte[] buffer, Int32 offset, Int32 count) +128
System.IO.BufferedStream.Read(Byte[] array, Int32 offset, Int32 count) +254
MySql.Data.MySqlClient.MySqlStream.ReadFully(Stream stream, Byte[] buffer, Int32 offset, Int32 count) +42
MySql.Data.MySqlClient.MySqlStream.LoadPacket() +64

[MySqlException (0x80004005): Reading from the stream has failed.]
MySql.Data.MySqlClient.MySqlStream.LoadPacket() +270
MySql.Data.MySqlClient.MySqlStream.ReadPacket() +32
MySql.Data.MySqlClient.Authentication.MySqlAuthenticationPlugin.ReadPacket() +39

[MySqlException (0x80004005): Authentication to host 'localhost' for user 'stock_SPDBUser' using method 'mysql_native_password' failed with message: Reading from the stream has failed.]
MySql.Data.MySqlClient.Authentication.MySqlAuthenticationPlugin.AuthenticationFailed(Exception ex) +177

Note: When i put connection string of Godaddy's MySQL works perfectly(MYSQL 5.5).

Note2: I use C# ASP.NET MVC 4 with the last version of MysqlData.DLL version.

c#
mysql

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0