Bug #48593 The connect with IPv6 as hostname fails in mtr tests.
Submitted: 6 Nov 2009 8:20 Modified: 1 Sep 2011 14:38
Reporter: Horst Hunger Email Updates:
Status: Closed Impact on me:
Category:Tools: MTR / mysql-test-run Severity:S3 (Non-critical)
Version:6.0-codebase OS:Any
Assigned to: Bjørn Munch CPU Architecture:Any

[6 Nov 2009 8:20] Horst Hunger
the following mysqltest statements failed:

echo connect (con1,, root,, test, $MASTER_MYPORT, );
connect (con1,, root,, test, $MASTER_MYPORT, );
echo disconnect con1;
disconnect con1;
echo connect (con2, ::1, root,, test, $MASTER_MYPORT, );
connect (con2, ::1, root,, test, $MASTER_MYPORT, );
echo disconnect con2;
disconnect con2;

While a connect with IP (IPv4) succeeded, the connect with the IP ::1 (IPv6) failed. the output:

main.ipv6_connect                        [ fail ]
        Test ended at 2009-11-06 09:13:33

CURRENT_TEST: main.ipv6_connect
mysqltest: At line 6: query 'connect  con2, ::1, root,, test, $MASTER_MYPORT, ' failed: 2003: Can't connect to MySQL server on '::1' (111)

The result from queries just before the failure was:
connect (con1,, root,, test, 13000, )
disconnect con1
connect (con2, ::1, root,, test, 13000, )

How to repeat:
- set "--skip-name-resolve", 
execute the statements above with the mtr.

Suggested fix:
IP's in IPv6 format shall be allowed (see 2nd connect statement).
[6 Nov 2009 18:37] Davi Arnaut
The server as started by mtr does not bind to ::1 (111 is ECONNREFUSED).
[8 Nov 2009 13:06] Valeriy Kravchuk
Please, try to repeat with recent mysql-6.0-codebase fron bzr and inform about the results. I have no problem with this test with revno 3642 dated Nov. 3 2009, for example.
[20 Nov 2009 11:19] Horst Hunger
After retrying the test with a new tree it worked as expected. So, no bug.