Bug #80749 doesn't automatically reconnect to server
Submitted: 15 Mar 2016 13:02 Modified: 2 Feb 2018 14:21
Reporter: Jon Harris Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Workbench: SQL Editor Severity:S4 (Feature request)
Version:6.3.6, 6.3.10, 8.0.24 OS:Windows (Microsoft Windows 10 Enterprise)
Assigned to: CPU Architecture:Any
Tags: WBBugReporter

[15 Mar 2016 13:02] Jon Harris
Description:
After a period of inactivity workbench generates:

Error Code: 2006. MySQL server has gone away

- It should reconnect automatically if given a new query. This behaviour did not occur in version 6.3.2

The DBMS connection keep-alive parameters (the three parameters in "MYSQL Session") have no apparent effect.

Connected database is running on MySQL 5.6.14 community server, on Windows 2012 server.

The workaround is to close workbench and reload - which is not productive. 

How to repeat:
Run a query, minimise, wait 20 minutes. Then retry.

Suggested fix:
Behaviour should be the same as the 6.3.2. If the MYSQL server has gone away, it should automatically reconnect.
[20 Apr 2016 12:54] Aaron Powers
I'm a big fan of MySQL workbench and am impressed it's free! Great tool, thank you for your hard work on it.

I have encountered the same regression -- for me too it worked in previous versions of MySQL Workbench.

First, I can add a partial workaround: In the menus, select "Query" -> "Reconnect to server". (Unfortunately there is no keyboard shortcut). However, this workaround does not fix all problems.

For example, if you click to expand a database in the "Schemas" tab when the connection has "gone away", the tables will not be visible. Even after reconnecting, "Refresh all" has no effect. The only way to get the table list is to collapse the database and re-open it. These kinds of secondary problems expand the scope of the error.
[24 Sep 2016 15:04] Richard Kuhn
For me this occurs within just a couple minutes of being idle. I have to switch to a different client until an auto reconnect is implemented since I feel its impacting my users productivity.
[3 Sep 2017 21:42] Michael Guillory
Well I see it's been a year since the last comment on this. I just started using Workbench again and am running into this issue now. I guess I'll have to content myself with phpMyadmin.
[2 Feb 2018 14:21] MySQL Verification Team
Hello Jon Harris,

Thank you for the feature request!

Thanks,
Umesh
[30 Apr 2021 13:38] MySQL Verification Team
Bug #103517 marked as duplicate of this one.