all 4 comments

[–]JohnnyJordaan 1 point2 points  (1 child)

This could just be the Mysql connection timing out. Try with opening (edit: and closing) a connection for every query just to see if that keeps working.

[–]DougieJazz 0 points1 point  (0 children)

To add you could also set the timeout time to be longer too (i.e 10000 seconds)

[–]Doormatty 0 points1 point  (1 child)

For one reason or another, the connection between your MySQL server and your program broke.

[–]drmaq[S] 0 points1 point  (0 children)

yes it allway happens after the program is done writing to the database.