avatar JayC Pro Jul 14. 2009. 8:56 am
I am receiving an occasional crash report with the message:

Query failed with message 'MySQL server has gone away'

There are only two times when this error is thrown.

Here is the first:

SELECT * FROM `acx_config_options` WHERE name = 'last_frequently_activity'

Here is the second:

INSERT INTO acx_incoming_mail_activity_logs (response, state, mailbox_id, created_on) VALUES ('Could Not Connect To Mailbox: SECURITY PROBLEM: insecure server advertised AUTH=PLAIN, Can not authenticate to IMAP server: [CLOSED] IMAP connection broken (authenticate)', '0', '1', '2009-06-27 08:00:59')

Any tips on either?
avatar Ilija Studen Staff Jul 14. 2009. 12:01 pm
Hi JayC,

Problem may occur on some servers and the cause of it is that MySQL, for one reason or another, closes connect in the middle of the request.

There is no way to actually prevent this, but what we have for the next release is a small piece of code that checks MySQL connection before each query and makes sure that it's alive. If not, system tries to reconnect (5 times) instead of throwing "MySQL server has gone away" error.

This fix will be included in the next bug fix release.
avatar JayC Pro Jul 14. 2009. 12:05 pm
Thank you for your clear response and integration of a solution into the next release!
avatar JayC Pro Jul 14. 2009. 4:49 pm
Discovery: these occasional crash reports stopped occurring when I uninstalled the beta Planning module.