Error Code: 2013. Lost connection to MySQL server during query

后端 未结 29 2115
深忆病人
深忆病人 2020-11-22 16:22

I got the Error Code: 2013. Lost connection to MySQL server during query error when I tried to add an index to a table using MySQL Workbench. I noticed als

29条回答
  •  慢半拍i
    慢半拍i (楼主)
    2020-11-22 16:24

    If all the other solutions here fail - check your syslog (/var/log/syslog or similar) to see if your server is running out of memory during the query.

    Had this issue when innodb_buffer_pool_size was set too close to physical memory without a swapfile configured. MySQL recommends for a database specific server setting innodb_buffer_pool_size at a max of around 80% of physical memory, I had it set to around 90%, the kernel was killing the mysql process. Moved innodb_buffer_pool_size back down to around 80% and that fixed the issue.

提交回复
热议问题