Bug #61725 Can't connect to MySQL Server after install IPv6 protocol in Windows XP SP3
Submitted: 2 Jul 2011 6:55 Modified: 18 Dec 2011 15:39
Reporter: MELERIX ... Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Server Severity:S1 (Critical)
Version:5.5.15 OS:Windows (XP SP3)
Assigned to: CPU Architecture:Any
Tags: ipv6

[2 Jul 2011 6:55] MELERIX ...
Description:
MySQL is installed and running properly on Windows XP SP3, but after install IPv6 Protocol and restart computer, now is impossible connect to MySQL Server.

If you uninstall IPv6 protocol, and restart computer again, it works ok.

How to repeat:
1 - Install MySQL on Windows XP SP3.
2 - MySQL Server is working and connection to MySQL Server is ok.
2 - Now Install IPv6 Protocol.
3 - Restart PC.
7 - After Restart PC, now is impossible connect to MySQL Server.
8 - Uninstall IPv6 Protocol and restart PC.
9 - Now is possible connect to MySQL Server.
[2 Jul 2011 7:44] Valeriy Kravchuk
What exact command do you use to connect and what error do you get when trying, in case of IPv6 installed?
[2 Jul 2011 7:48] MELERIX ...
to connect I use MySQL Workbench or Navicat.
[2 Jul 2011 7:55] MELERIX ...
Error message is:

2003 - Can't Connect to MySQL server on 'localhost' (10061)

NOTE: My Windows Hosts files is ok.
[2 Jul 2011 8:08] MELERIX ...
edit
[3 Jul 2011 2:20] Vladislav Vaintroub
XP, unlike all newer versions of Windows, does not support TCP dual stack - that is  server can't listen on both IPv4 and IPv6 ports. Older clients, that do not understand IPv6 (I presume Navicat and Workbench would use older client libraries) would not be able to connect, if server listens on IPv6 only.

Lack of dual stack rendered XP/2003 IPv6 hardly usable for server-type software back in the days, as client software was overwhelmingly IPv4.

Very likely, on XP this situation could be fixed/avoided using "bind-address" option and setting it to the IPv4 address of the box (maybe ?  to 127.0.0.1)

Also likely, mysql command line client supplied with 5.5 as well as clients using newer libraries could work just fine with mysqld listening on IPv6 address.
[3 Jul 2011 2:21] Quanah Gibson-Mount
This is not an XP only issue.  It also affects linux, is new with 5.5, and is clearly a bug.

See http://bugs.mysql.com/61713
[3 Jul 2011 2:36] Vladislav Vaintroub
I commented on Windows only, because I happen to know about it. If OS does not support dual stack (Windows XP one of BSD variations ?), or it is disabled somehow, "clearly a bug" is not entirely clear, because there is now a choice to run on either IPv6 or IPv4. If OS prefers to use IPv6 and user IPv4, user should blame the OS . MySQL Server does not force that choice, it is just using IPv independent APIs.

Wlad(not affiliated to Oracle)
[3 Jul 2011 2:38] Vladislav Vaintroub
Besides, the other bug is about something else..
[3 Jul 2011 3:36] MELERIX ...
even if you try to connect to "127.0.0.1" or "::1" (instead of "localhost") is still impossible to connect to MySQL Server.
[16 Jul 2011 15:49] Valeriy Kravchuk
Please, send your my.ini file content. I wonder if you have bind-address there...
[17 Jul 2011 1:45] MELERIX ...
my.ini created with "MySQLInstanceConfig"

Attachment: my.ini (application/octet-stream, text), 8.75 KiB.

[20 Aug 2011 2:10] MELERIX ...
updated version to 5.5.15 because issues is still present in 5.5.15
[18 Dec 2011 15:39] Valeriy Kravchuk
If we speak about XP only, this is a duplicate of Bug #61163.
[15 Nov 2012 22:34] Bill Ince
So I have a workaround that works on my Windows Server 2003 box and I thought I would share...

All you have to do is map a proxy port from IPV4 to IPV6.  Here is the command:
netsh interface portproxy add v4tov6 listenport=3306 connectaddress=::1 connectp
ort=3306

Good luck all!