nakagami/CyMySQL

Lost connection to MySQL server during query (after 0.8.2 -> 0.8.4)

olafsep01 opened this issue · 3 comments

After upgrading to 0.8.4 I get this error frequent. I did a new 0.8.2 install via setup.py and it worked again. Then I did a install of 0.8.3 via setup.py and I got this error.
This error is not exact reproducible. But it occurs after "many" select queries. It look likes it happens with a bigger select query (more data to return).

File "cymysql/cursors.py", line 259, in cymysql.cursors.DictCursor.execute (cymysql/cursors.c:6594)
File "cymysql/cursors.py", line 133, in cymysql.cursors.Cursor.execute (cymysql/cursors.c:4285)
File "cymysql/cursors.py", line 35, in cymysql.cursors.Cursor.errorhandler (cymysql/cursors.c:1639)
File "cymysql/connections.py", line 118, in cymysql.connections.Connection.errorhandler (cymysql/connections.c:4189)
File "cymysql/cursors.py", line 128, in cymysql.cursors.Cursor.execute (cymysql/cursors.c:4093)
File "cymysql/cursors.py", line 234, in cymysql.cursors.Cursor._query (cymysql/cursors.c:6219)
File "cymysql/connections.py", line 341, in cymysql.connections.Connection.query (cymysql/connections.c:9315)
File "cymysql/packet.pyx", line 285, in cymysql.packet.MySQLResult.init (cymysql/packet.c:6392)
File "cymysql/packet.pyx", line 295, in cymysql.packet.MySQLResult.read_rest_rowdata_packet (cymysql/packet.c:6561)
File "cymysql/packet.pyx", line 61, in cymysql.packet.MysqlPacket.init (cymysql/packet.c:1470)
File "cymysql/packet.pyx", line 87, in cymysql.packet.MysqlPacket.__recv_packet (cymysql/packet.c:1838)
cymysql.err.OperationalError: (2013, 'Lost connection to MySQL server during query')

It is always a select statement (where and order by). The connection to mysql is via tcp-ip (from one virtual machine to another (virtualbox), same hardware).
I am running:
client:

Kernel : Linux 3.13.0-63-generic (x86_64)
Compiled : PyMySQL#103-Ubuntu SMP Fri Aug 14 21:42:59 UTC 2015
Default C Compiler : GNU C Compiler version 4.8.4 (Ubuntu 4.8.4-2ubuntu1~14.04)
Distribution : Ubuntu 14.04.3 LTS

python: 3.4
cython: 0.23.3

server:
-Version-
Kernel : Linux 3.13.0-63-generic (x86_64)
Compiled : PyMySQL#103-Ubuntu SMP Fri Aug 14 21:42:59 UTC 2015
Default C Compiler : GNU C Compiler version 4.8.4 (Ubuntu 4.8.4-2ubuntu1~14.04)
Distribution : Ubuntu 14.04.3 LTS

mysql: mariadb 5.5.44

Probably fix it in repository master branch.
Can you install and test with current master branch ?

Thanks. It works again :). Let me know when I can close the issue.

Thanks
0.8.5 has released now, and fix it.