"MySQL server has gone away" error
Added by Dmitry Lyumkis almost 10 years ago
Long appion jobs (e.g. alignments & classification) require long connections to MySQL. If you receive an error such as the following:
"_mysql_exceptions.OperationalError: (2006, 'MySQL server has gone away’)"
this is because MySQL has opened a connection to the database (upon launching the job), but then remained idle for a time that is longer than what is specified in the configuration settings, probably because the job is running. The "wait_timeout" variable defines the number of seconds the server waits for activity on a noninteractive connection before closing it. This is defaulted to 28800 seconds (8 hours). Thus, if your job takes >8 hours to run, you will receive the above error. You can increase the time by setting, for example, --wait_timeout = 100000 in my.cnf (usually /etc/my.cnf) under mysqld (the MySQL server). Note that you will need root privileges to do this.