‘MySQL server has gone away’解决方法

错误:

ERROR sqlalchemy.pool.QueuePool Exception during reset or similar

2017-02-20 10:16:38,016 INFO sqlalchemy.pool.QueuePool Invalidate connection <_mysql.connection open to '127.0.0.1' at 29427b0> (reason: OperationalError:(2006, 'MySQL server has gone away'))

解决:

参考链接:https://dev.mysql.com/doc/refman/5.7/en/gone-away.html

在/usr/local/mysql/my.cnf文件里加上如下(不用重启):

max_allowed_packet = 16M

wait_timeout=2880000

interactive_timeout = 2880000

done!

你可能感兴趣的:(‘MySQL server has gone away’解决方法)