Bug #40715 mtr fails when running the same test case in parallel threads
Submitted: 13 Nov 2008 19:32 Modified: 30 Jan 2009 17:52
Reporter: Sven Sandberg Email Updates:
Status: Closed Impact on me:
None 
Category:Tests Severity:S7 (Test Cases)
Version:5.1-rpl, 6.0-rpl OS:Any
Assigned to: Magnus BlÄudd CPU Architecture:Any
Tags: mtr

[13 Nov 2008 19:32] Sven Sandberg
Description:
When running './mtr --parallel=2 rpl_alter_db rpl_alter_db', mtr fails with the error message:

mysql-test-run: *** ERROR: ' rpl.rpl_alter_db ' is not known to be running

This is repeatable for any test, not just rpl_alter_db. Seems that mtr does not handle the case when the same test case and same combination is run in two parallel threads.

Moreover, if you run with --verbose, it looks as if the main thread loses the auxiliary thread, and stops before the auxiliary thread has stopped: the main thread exits and you return to the shell prompt, but after a few seconds the auxiliary thread prints a lot of text to stdout again.

How to repeat:
$ ./mtr --force rpl_alter_db rpl_alter_db
Logging: ./mtr  --force rpl_alter_db rpl_alter_db
MySQL Version 6.0.9
Checking supported features...
 - using ndbcluster when necessary, mysqld supports it
 - SSL connections supported
 - binaries are debug compiled
Collecting tests...
 - adding combinations for rpl
vardir: /home/sven/bzr/b38350-test_cleanup/6.0-rpl/mysql-test/var
Checking leftover processes...
Removing old var directory...
Creating var directory '/home/sven/bzr/b38350-test_cleanup/6.0-rpl/mysql-test/var'...
Installing system database...
Using parallel: 2
Using server port 37964
worker[1] Using MTR_BUILD_THREAD 11, with reserved ports 10110..10119
Removing slot 250 used by missing process 3217
worker[2] Using MTR_BUILD_THREAD 250, with reserved ports 12500..12509

============================================================

TEST                                      RESULT   TIME (ms)
------------------------------------------------------------

rpl.rpl_alter_db 'row'                   [ pass ]    128
rpl.rpl_alter_db 'row'                   [ pass ]    236
mysql-test-run: *** ERROR: ' rpl.rpl_alter_db ' is not known to be running
[14 Nov 2008 10:49] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/58757

2694 Magnus Svensson	2008-11-14
      Bug#40715 mtr fails when running the same test case in parallel threads
[30 Jan 2009 13:26] Bugs System
Pushed into 6.0.10-alpha (revid:luis.soares@sun.com-20090129165607-wiskabxm948yx463) (version source revid:luis.soares@sun.com-20090129163120-e2ntks4wgpqde6zt) (merge vers: 6.0.10-alpha) (pib:6)
[30 Jan 2009 15:07] Bugs System
Pushed into 5.1.32 (revid:luis.soares@sun.com-20090129165946-d6jnnfqfokuzr09y) (version source revid:msvensson@mysql.com-20081114104912-kbcj7q37dyty00sy) (merge vers: 5.1.31) (pib:6)
[30 Jan 2009 17:52] Paul DuBois
Test suite changes. No changelog entry needed.
[17 Feb 2009 14:52] Bugs System
Pushed into 5.1.32-ndb-6.3.23 (revid:tomas.ulin@sun.com-20090217131017-6u8qz1edkjfiobef) (version source revid:tomas.ulin@sun.com-20090203133556-9rclp06ol19bmzs4) (merge vers: 5.1.32-ndb-6.3.22) (pib:6)
[17 Feb 2009 16:40] Bugs System
Pushed into 5.1.32-ndb-6.4.3 (revid:tomas.ulin@sun.com-20090217134419-5ha6xg4dpedrbmau) (version source revid:tomas.ulin@sun.com-20090203133556-9rclp06ol19bmzs4) (merge vers: 5.1.32-ndb-6.3.22) (pib:6)
[17 Feb 2009 18:16] Bugs System
Pushed into 5.1.32-ndb-6.2.17 (revid:tomas.ulin@sun.com-20090217134216-5699eq74ws4oxa0j) (version source revid:tomas.ulin@sun.com-20090201210519-vehobc4sy3g9s38e) (merge vers: 5.1.32-ndb-6.2.17) (pib:6)