Bug #69663 "localhost" doesn't work for IPv6-only bound host in WB
Submitted: 3 Jul 2013 15:27 Modified: 20 Apr 2017 14:19
Reporter: Todd Farmer (OCA) Email Updates:
Status: Closed Impact on me:
Category:MySQL Workbench: SQL Editor Severity:S3 (Non-critical)
Version:5.2.45 OS:Windows
Assigned to: CPU Architecture:Any

[3 Jul 2013 15:27] Todd Farmer
After starting a MySQL Server instance that is bound to only the IPv6 interface, WB fails to connect to "localhost".  This contrasts with the behavior seen using the mysql cli:

D:\mysql-5.6.10-win32>bin\mysql.exe -uroot -h127.0.0.1
ERROR 2003 (HY000): Can't connect to MySQL server on '' (10061)

D:\mysql-5.6.10-win32>bin\mysql.exe -uroot -hlocalhost
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 8

WB does, however, connect successfully when the host address "::1" is used.  

How to repeat:
1. Start a MySQL Server bound to IPv6 interface only.
2. Try to connect using WB to this server using "localhost".
3. Try the same thing using the mysql cli.

Suggested fix:
WB should understand "localhost" in the context of both IPv4 and IPv6 interfaces, as the cli does.
[20 Apr 2017 14:19] Paul DuBois
Posted by developer:
Noted in 1.1.9 changelog.

Connections to localhost failed if the local server was bound only to
its IPv6 interface.